performance question with htmlspecialchars,strip_tags

From: Date: Mon, 12 May 2003 14:57:16 +0000
Subject: performance question with htmlspecialchars,strip_tags
Groups: php.general 
Request: Send a blank email to php-general+get-147308@lists.php.net to get a copy of this message
Hi, I am programming for a webhosting directory site (to be) and we have some really huge forms...with as much as 45 fields in a single form and quite a few text/hidden boxes, multiply that by around 5-10 forms.... As you can imagine I dont want some jackass spoiling my neat tables by entering <h1> hahaha got you</h1> into it...so would you suggest I use HTMLSPECIALCHARS or STRIP_TAGS to do it? If I use either, will it slow down the rate of execution noticably? I am kind of leaning towards HTMLSPECIALCHARS as if someones name is Ryan 'O Conner it will happily take care of the " ' " there or if he accidentally puts Ryan "O Conner it will replace that with too...no need of the addslashes/strip slashes thing. Any experience with this and what do you suggest? Kindly reply. Cheers, -Ryan

« previous php.general (#147308) next »