PHP function strip_tags()

Availability in PHP 4.0

Strip HTML and PHP tags from a string

Parameters

Parameter Data type Default value Note
$str string not Input string.
$allowable_tags string null You can use the second optional parameter to specify tags that should not be removed.

Return values

string

the stripped string.

Other resources

Official documentation for the strip-tags function

Newsletter

Nejlepsi tipy a triky o PHP do Vaseho e-mailu. Clanky a novinky nejen ze sveta PHP a programovani.