tag_escape WordPress Filter Hook

The tag_escape hook is used to escape HTML tags in content. This is useful for preventing cross-site scripting (XSS) attacks.

apply_filters( 'tag_escape', string $safe_tag, string $tag_name ) #

Filters a string cleaned and escaped for output as an HTML tag.


Parameters

$safe_tag

(string)The tag name after it has been escaped.

$tag_name

(string)The text before it was escaped.


Top ↑

Source

File: wp-includes/formatting.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
2.8.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More