我想编辑默认函数the_content()
. 我知道我可以add_filter(\'the_content\', \'with_my_function\')
但是我在输出旧内容时遇到了麻烦。
这是我正在做的一个例子。
add_filter(\'the_content\', \'my_function\');
function my_function()
{
$write = \'hello world\';
$content = apply_filters(\'the_content\', get_the_content());
echo $write.$content;
}
我怎样才能让它工作?