strip_shortcode_tag()
Strips a shortcode tag based on RegEx matches against post content.
Хуков нет.
Возвращает
string|false. The content stripped of the tag, otherwise false.
Использование
strip_shortcode_tag( $m );
- $m(массив) (обязательный)
- RegEx matches against post content.
Список изменений
| С версии 3.3.0 | Введена. |
Код strip_shortcode_tag() strip shortcode tag WP 7.1.4
function strip_shortcode_tag( $m ) {
// Allow [[foo]] syntax for escaping a tag.
if ( '[' === $m[1] && ']' === $m[6] ) {
return substr( $m[0], 1, -1 );
}
return $m[1] . $m[6];
}