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 " before
outputting $row[4] (or simply run htmlspecialchars() on it before
outputting).
Cheers,
NC
[Back to original message]
|