note 52173 added to function.strip-tags

From: Date: Sat, 23 Apr 2005 00:09:33 +0000
Subject: note 52173 added to function.strip-tags
Groups: php.notes 
Request: Send a blank email to php-notes+get-88428@lists.php.net to get a copy of this message
I think bryn and john780 are missing the point - eric at direnetworks wasn't suggesting there is an overall string limit of 1024 characters but rather that actual tags over 1024 characters long (eg, in his case it sounds like a really long encrypted <a href> tag) will fail to be stripped. The functions to slowly pass strings through strip_tags 1024 characters at a time aren't necessary and are actually counter productive (since if a tag spans the break point, ie it is opened before the 1024 characters and closed after the 1024 characters then only the opening tag is removed which leaves a mess of text up to the closing tag). Only mentioning this as I spent ages working out a better way to deal with this character spanning before I actually went back and read eric's post and realised the subsequent posts were misleading - hopefully it'll save others the same headaches :) ---- Manual Page -- http://www.php.net/manual/en/function.strip-tags.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+52173 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+52173&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+52173&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+52173&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+52173&report=yes&reason=useless Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+52173&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+52173&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#88428) next »