Re: Problem with GD after upgrading Entropy 5.1.6 -> 5.2.2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



M5 wrote:
I've got a little PHP script that generates charts, that has been working perfectly every day for the past couple years. Since upgrading the Xserve's PHP from 5.1.6 to 5.2.2 (both Entropy), it has stopped working. Specifically, it doesn't return any GIFs (charts). Actually, it will output a GIF providing that session_start() isn't called at the beginning of chart.php. The reason session_start() is called is that the data needed by chart.php resides as session variables—so the session needs to be propogated to chart.php when it's called.

My gut feeling is that *something* in chart.php is now throwing a notice or warning or something, and that is corrupting the GIF file (which returns as a broken icon). Here's the beginning of chart.php, which as I mentioned, was working perfectly verbatim up until last week:

<?php

session_start();
error_reporting(0);
header("Content-type: image/gif");

[...]

Here is a modified version of the above, based on comments I've gleaned from various forums. (It still doesn't work, btw.)


<?php

@session_start();
@set_time_limit(0);
@error_reporting(0);

// session_start();

header("Content-type: image/gif");
header("Cache-Control: cache, must-revalidate");
header("Pragma: public");

[...]


...Rene




Maybe see if display_errors is on, if so, ini_set('display_errors', 0); might help

but what you might want to do is turn on everything for error reporting and view the page with the gif output part disabled and see what it says.

<?php

error_reporting(E_ALL);
ini_set('display_errors', 'On');

...



now browse to the page and see what it says. Make sure you comment out the header part that sends a custom Content-type also.



--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
    by William Shakespeare

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux