函数原型
apply_shortcodes( string $content, bool $ignore_html = false ): string
函数描述
Searches content for shortcodes and filter shortcodes through their hooks.
是否弃用
未弃用
函数参数
-
$content
string
Required - Content to search for shortcodes.
-
$ignore_html
bool
Optional - When true, shortcodes inside HTML elements will be skipped.
Default:
false
函数返回值
string Content with shortcodes filtered out.
函数位置
File: wp-includes/shortcodes.php.
函数源码
function apply_shortcodes( $content, $ignore_html = false ) {
return do_shortcode( $content, $ignore_html );
}
源码链接
变更日志
| Version | Description |
|---|---|
| 5.4.0 | Introduced. |

