Definition
The strip_tags() function strips a string from HTML, XML, and PHP tags.
Syntax
strip_tags(string, allow)
Parameters
Parameter | Description |
---|---|
string |
Required. Specifies the string to check. |
allow |
Optional. Specifies allowable tags. These tags will not be removed. |
Example
<?php
echo strip_tags("Welcome to <b>PHP!</b>");