RE: [PHP-DB] CMS error

From: Date: Mon, 16 Dec 2002 17:21:50 +0000
Subject: RE: [PHP-DB] CMS error
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-24183@lists.php.net to get a copy of this message
> I have a field in a news CMS that could contain " Infact most of the time > it > does in the form of URL's etc. Getting the data initially into the > database > is no problem - Infact MySQL shows has no toruble with it. The problem i > am > getting is when i edit the data - basically loading into a form -> > textarea. > The data displays everything after the first " appears but in a small > textarea. > I have looked at addslashes() which insnt apropriate in this instance as > the > text area has no problem with the slashes. > Is there an equivalent for " or am i worth substituting them for a > character > when i load them into my edit field. > I can imagine this is a common probem in CMS - any suggestions on a quick > fix..? If you're doing it like <textarea>$value</textarea> Then it shouldn't matter if there are double quotes within $value. If you're doing it like <input type="text" value="$value"> Then you'll have to use htmlentities() on $value before you place it between the double quotes. If that doesn't help, show your code. ---John Holmes...

« previous php.db (#24183) next »