I'm debugging a script I inherited. As I've debugged this script, I'm down to the end now. As it seems everything is OK now, I'm now stumped. Here's the error:
PHP Parse error: parse error, unexpected $ in - on line 172
Below, I've included the last 18 lines. As I've skimmed the code for any extraneous characters or missing parts, my eyes see nothing. Take a look:
155 # For desperate debugging.
156 # Because "printing" writes to the image file.
157 if (6 == 9) {
158 $fp = fopen ("tinyplotdmp.txt","w");
159
160 fwrite($fp,"Reportfile = $reportfile\n");
161 fwrite($fp,"FEEDS = $_SERVER[FEEDS]\n");
162 fwrite($fp,"IMAGES = $_SERVER[IMAGES]\n");
163 fwrite($fp,"PROGS = $_SERVER[PROGS]\n");
164 fwrite($fp,"PHP_INC_PATH = $_SERVER[PHP_INC_PATH]\n");
165 fwrite($fp,"PUBLIC = $_SERVER[PUBLIC]\n");
166 fwrite($fp,"GD_TYPE = $_SERVER[GD_TYPE]\n");
167 fwrite($fp,"CACHE = $_SERVER[CACHE]\n");
168
169 fclose($fp);
170 }
171 ?>
Where's the error for ln 172 coming from? Is there most likely something higher in the script that's the cuprit? The only sugggestion tsWebEditor offers is a block of HTML at the end, but this is not a script that generates web pages; it does, however, generate graphics.
Thanks,
monger