WordPress是否像Joomla那样提供插件覆盖功能?
我想用与Joomla类似的方式覆盖WordPress插件的输出,这可能吗?您可以在输出数据之前使用过滤器更改数据 或者可以使用WordPress是否像Joomla那样提供插件覆盖功能?,joomla,wordpress,Joomla,Wordpress,我想用与Joomla类似的方式覆盖WordPress插件的输出,这可能吗?您可以在输出数据之前使用过滤器更改数据 或者可以使用模板\u include过滤器提供不同的自定义模板。 e、 g function choose_template($template) { if( $template == 'plugin-template-page.php' ) { $template = 'my-template-page.php'; } return $template;
模板\u include
过滤器提供不同的自定义模板。
e、 g
function choose_template($template)
{
if( $template == 'plugin-template-page.php' )
{
$template = 'my-template-page.php';
}
return $template;
}
add_filter('template_include','choose_template');