Re: Re: Inserting querydata as default value in form

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Neil Smth" <php@xxxxxxxxxxxxxxxxxxxxxxxx>

> When will people learn that attributes in HTML ,and *especially* in forms
> MUST BE QUOTED ! This will really really screw you up if you ever have to
> make an xhtml page (and you'll be back here again). Please please get into
> this practice, it will save you a lot of headaches even short term.
>
> So, change your line to
>
> <input name="link" id="link" type="text" cols="40"
> value="<?=$query_data[4]?>" />

And so you don't come back with problems/questions when $query_data[4] has
double quotes in it, you should do this:

> <input name="link" id="link" type="text" cols="40"
> value="<?=htmlentities($query_data[4],ENT_QUOTES)?>" />

If it hasn't been done to the data already.

---John Holmes...

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux