Fix in strip_tags
| From: | Adam Kazimierczak | Date: | Thu, 13 Jun 2013 22:23:18 +0000 |
| Subject: | Fix in strip_tags | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969384399@lists.php.net to get a copy of this message | ||
Hello again,
In strip_tags there is a note that says:
---
This parameter should not contain whitespace. strip_tags sees a tag as a case-insensitive string between /</ and the first whitespace or />/. It means that /strip_tags("<br/>", "<br>")/ returns an empty string.
---
The given code, obviously, will not return an empty string. Probably someone forgot to add an example whitespace to the code. I updated the second parameter in the example from <br> to <br >.
Cheers,
Adam
Attachment: [text/x-patch] strip-tags.xml.patch
Attachment: [text/x-patch] strip-tags.xml.patch