This is a discussion on obscure bug related to size of script file? within the PHP Language forums, part of the PHP Programming Forums category; hi i am having a problem with a php script i am trying to write. the problem is that the ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
hi
i am having a problem with a php script i am trying to write. the problem is that the ouput from the script (the html) was sometimes being truncated, but sometimes it would work as expected. i managed to narrow the problem down (believe it or not) to the difference between a sinle character anywhere in the script. by this i mean, for example, when the php script was at 10,589 bytes it worked perfectly. if i took one character out from anywhere in the in the script (and i mean anywhere, changed a printf to a print, or took a character from a php comment, or took a char from some html outside the php scriplets, or changed a number from say 100 to 99) it would fail!!!! and by fail i mean the result that was being received by my browser was truncated about half way down the page (in the middle of some html from the script!). i am totally totally blown away by this obscure bug. has anyone seen anything like it? maybe it is fixed in later versions of php? the stuff i am running is: PHP 4.3.3 (cgi) (built: Sep 1 2003 04:45:21) Copyright (c) 1997-2003 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2003 Zend Technologies RedHat Linux 7.x OS Apache/1.3.27 Server thanks Ryan |
|
|||
|
Ok, so i finally figured it out...
turns out it was a bug in the ftp client i was using to upload that was truncating the script!!! must have been the sequence of chars in the script not being escaped properly or something.. lol, what a pain! Ryan "Ryan" <ryan@someplace.com> wrote in message news:3fb6faeb@news.comindico.com.au... > hi > > i am having a problem with a php script i am trying to write. > the problem is that the ouput from the script (the html) was > sometimes being truncated, but sometimes it would work > as expected. > > i managed to narrow the problem down (believe it or not) to > the difference between a sinle character anywhere in the script. > > by this i mean, for example, when the php script was at 10,589 bytes > it worked perfectly. if i took one character out from anywhere in > the in the script (and i mean anywhere, changed a printf to a print, > or took a character from a php comment, or took a char from some > html outside the php scriplets, or changed a number from say 100 to 99) > it would fail!!!! and by fail i mean the result that was being received > by my browser was truncated about half way down the page (in the > middle of some html from the script!). > > i am totally totally blown away by this obscure bug. has anyone > seen anything like it? maybe it is fixed in later versions of php? > > the stuff i am running is: > > PHP 4.3.3 (cgi) (built: Sep 1 2003 04:45:21) > Copyright (c) 1997-2003 The PHP Group > Zend Engine v1.3.0, Copyright (c) 1998-2003 Zend Technologies > > RedHat Linux 7.x OS > > Apache/1.3.27 Server > > > thanks > > Ryan > > |