For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > September 2007 > Re: [PHP-DB] Data not fetching in the textfield.









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PHP-DB] Data not fetching in the textfield.
Chris

2007-09-26, 9:59 pm


<snip>

> echo("<input name=\"input1\" type=\"text\" value=$rows[0]>");


Change to

echo"<input name=\"input1\" type=\"text\" value=\"" .
htmlspecialchars($rows[0], ENT_QUOTES) . "\">";

So html characters like > and < won't be interpreted by the browser.

--
Postgresql & php tutorials
http://www.designmagick.com/
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com