You are here: Re: stripslashes problem (American Inch Marks = ") « PHP Programming Language « IT news, forums, messages
Re: stripslashes problem (American Inch Marks = ")

Posted by NC on 05/18/06 18:39

Terry wrote:
>
> <form>
> <textarea id=\"description\" name=\"description\">$row[3]</textarea>
> <label>Grip Sizes </label><input type=\"text\" id=\"grip\"
> name=\"grip\" maxlength=\"60\" size=\"60\" value=\"$row[4]\">
> [Submit]
> </form>
>
> $description will display whatever is entered ' and "
> $grip will truncate anything after the " when the record comes up for
> modification.
>
> The only difference I can see is one is a textarea, the other an input box.

Not only that; the "value" attribute in the "grip" input is enclosed in
double quotes. So outputting a double quote inside the attribute
closes the value. You need to replace double quotes with &quot; before
outputting $row[4] (or simply run htmlspecialchars() on it before
outputting).

Cheers,
NC

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация