Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.8.0

Bug #2832 GD always outputs PNG
Submitted: 2004-11-25 23:21 UTC
From: oliver at burtchen dot com Assigned: nosey
Status: Closed Package: Image_Graph
PHP Version: 5.0.2 OS:
Roadmaps: (Not assigned)    
Subscription  
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes. If this is not your bug, you can add a comment by following this link. If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
2006-12-27 04:51 UTC
Package:
Bug Type:
Summary:
From: oliver at burtchen dot com
New email:
PHP Version: Package Version: OS:

 

 [2004-11-25 23:21 UTC] oliver at burtchen dot com
Description: ------------ Using Image_Graph-0.3.0dev2-pre: The GD-driver always outputs PNG to the browser, if you don't set a file name. The only way to get JPG-output is to set a filename ending with '.jpg', even if you don't need the file.

Comments

 [2004-11-26 07:19 UTC] pear dot nosey at veggerby dot dk
True it does, I'll add an option, so that you can specify output format, i.e. something like: $Graph->done(array('output' => 'jpg'));
 [2004-11-26 16:22 UTC] oliver at burtchen dot com
Well, thanks for your reply. I saw in CVS (driver.php) there is a $param['format'] for the driver-factory methode to distinguish between PNG and JPG. But it's not used by GD at the end. So what's with it? Second I saw a typo in gd.php where function done($param = false) { parent::done($param); if (($param === false) or (!isset($param['filename']))) { $output = 'png'; if (($param !== false) and (isset($param['output']))) { -----> $outout = $param['output']; } should be -----> $output = $param['output']; Third, I like Image_Graph very much!!! ;-)