#21744 [Ver->Asn]: strip_slashes misses exclamation marks in alt text

From: Date: Sun, 19 Jan 2003 11:13:20 +0000
Subject: #21744 [Ver->Asn]: strip_slashes misses exclamation marks in alt text
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-30552@lists.php.net to get a copy of this message
 ID:               21744
 Updated by:       rasmus@php.net
 Reported By:      dan@freelancer.net
-Status:           Verified
+Status:           Assigned
 Bug Type:         Unknown/Other Function
 Operating System: Linux
 PHP Version:      4.3.0
-Assigned To:      moriyoshi
+Assigned To:      rasmus
 New Comment:

My fault.  I'll fix it soonish.


Previous Comments:
------------------------------------------------------------------------

[2003-01-19 05:10:35] moriyoshi@php.net

Verified with HEAD

------------------------------------------------------------------------

[2003-01-19 04:58:46] dan@freelancer.net

Tried the same using PHP 4.0.6 and did not get the problem:

[admin@labworks ukshopsearch]$ php
<?
print strip_tags('<IMG ALT="Bang Not Stripped!">') . "\n";
?>
X-Powered-By: PHP/4.0.6
Content-type: text/html


[admin@labworks ukshopsearch]$

------------------------------------------------------------------------

[2003-01-19 04:39:37] dan@freelancer.net

The following code prints "!" (without the quotes):

print strip_tags('<IMG ALT="Bang Not Stripped!">');

I would expect it to print nothing.

Same thing happens here:

print strip_tags('<AREA ALT="Bang Not Stripped!">');

Here is an example copied from the command line:

[dan@192 v008]$ php
<?
print strip_tags('<IMG ALT="Bang Not Stripped!">') . "\n";
?>
!
[dan@192 v008]$ 

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=21744&edit=1



Thread (7 messages)

« previous php.bugs (#30552) next »