PHP

PHP Menu

PHP

strip_tags() Function - Definition, Syntax, Parameters, Examples

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>");

Introduction

PHP Basics

PHP Advance

PHP OOP

PHP Functions and Methods