1
0
mirror of https://github.com/php/php-src.git synced 2026-03-27 01:32:22 +01:00
This commit is contained in:
Ilia Alshanetsky
2002-11-27 06:20:37 +00:00
parent 3033a27023
commit 4ec67e7df3
2 changed files with 5 additions and 0 deletions

View File

@@ -3496,6 +3496,8 @@ PHPAPI void php_strip_tags(char *rbuf, int len, int *stateptr, char *allow, int
/* JavaScript & Other HTML scripting languages */
if (state == 1 && *(p-1) == '<') {
state = 3;
} else {
*(rp++) = c;
}
break;

View File

@@ -16,6 +16,8 @@ strip_tags() function
echo "\n";
echo strip_tags('NEAT <? echo \'\\\'\'?> STUFF');
echo "\n";
echo strip_tags('TESTS ?!!?!?!!!?!!');
echo "\n";
?>
--EXPECT--
NEAT STUFF
@@ -24,3 +26,4 @@ NEAT STUFF
NEAT STUFF
NEAT STUFF
NEAT STUFF
TESTS ?!!?!?!!!?!!