CodeIgniter Forums
Profiler bug line 168 - 169 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Profiler bug line 168 - 169 (/showthread.php?tid=2358)



Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]Jamongkad[/eluser]
As I have posted on the freakauth 1.1 thread

Quote:@DanFreak

Since we're in the process of fine tuning Fal I would like to introduce another niggle hehe. Once I got the myaccount/edit controler/method working. CI seems to spout out a strange but interesting error.

Code:
Parse error: syntax error, unexpected '"', expecting T_STRING or T_VARIABLE or T_NUM_STRING in C:\wamp\www\myswebsite\system\libraries\Profiler.php on line 169

Upon inspection of this of Profiler.php line 169
Code:
line 168://$output .= "<tr><td width='50%' style='color:#000;background-color:#ddd;'>$_POST[".$key."]&nbsp;&nbsp;</td><td width='50%' style='color:#009900;font-weight:normal;background-color:#ddd;'>".htmlspecialchars(stripslashes($val))."</td></tr>\n";

line 169:$output .= "<tr><td width='50%' style='color:#000;background-color:#ddd;'>$_POST[".$key."]  </td><td width='50%' style='color:#009900;font-weight:normal;background-color:#ddd;'>";

It seems line 168 was commented out to make room for line 169. So as an experiment decided to comment out line 169 as well and lo and behold it worked! but there was this weird benchmark result that comes out of the bottom of the edit form..

please click on link below(sorry I don't know how does this forum display images).
[Image: error.jpg]
A pic of the error in this link:
[Image: error.jpg]

My tools:
Code Igniter 1.5.3
FreakAuth_light_1.1

I will attempt to fix this on my own :-) but help from Rick and the gang would be nice.


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]coolfactor[/eluser]
This was fixed in CI v1.5.4.


(edited)


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]coolfactor[/eluser]
Okay, I think it's trying to parse the $_POST in there. It would be better to swap the single and double quotes.

Code:
line 169:$output .= '<tr><td width="50%" style="color:#000;background-color:#ddd;">$_POST['.$key.']</td><td width="50%" style="color:#009900;font-weight:normal;background-color:#ddd;">';



Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]coolfactor[/eluser]
Revised my post. Bump.


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]Jamongkad[/eluser]
Thanks CF when I corrected this the Benchmark still shows itself at the bottom of my edit form.... Sad


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]coolfactor[/eluser]
Sorry man, I don't use the Profiler. Only going by what you posted. I could be missing something important in the rest of the code. Probably want to leave that commented out for now.


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]Jamongkad[/eluser]
[quote author="coolfactor" date="1185924025"]Sorry man, I don't use the Profiler. Only going by what you posted. I could be missing something important in the rest of the code. Probably want to leave that commented out for now.[/quote]

Thanks man, I'll leave that commented out as well.


Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]Derek Jones[/eluser]
This was fixed in 1.5.4, Jamon.

Quote:Fixed a bug in display of POST keys in the Profiler output



Profiler bug line 168 - 169 - El Forum - 07-31-2007

[eluser]Jamongkad[/eluser]
[quote author="Derek Jones" date="1185929770"]This was fixed in 1.5.4, Jamon.

Quote:Fixed a bug in display of POST keys in the Profiler output
[/quote]

Oh ok thank you!