在genesis函数中包含PHP语句

在genesis函数中包含PHP语句,php,wordpress,Php,Wordpress,我正在使用Wordpress主题(genesis框架),我需要在post元函数中输入一个php代码片段(就在post_编辑之后)。我似乎无法在不出错的情况下让它正常工作 这是我需要使用的功能: add_filter( 'genesis_post_info', 'sp_post_info_filter' ); function sp_post_info_filter($post_info) { $post_info = '[post_date] by [post_author_posts_

我正在使用Wordpress主题(genesis框架),我需要在post元函数中输入一个php代码片段(就在post_编辑之后)。我似乎无法在不出错的情况下让它正常工作

这是我需要使用的功能:

add_filter( 'genesis_post_info', 'sp_post_info_filter' );
function sp_post_info_filter($post_info) {
    $post_info = '[post_date] by [post_author_posts_link] [post_comments] [post_edit]';
    return $post_info;
}
这是我需要使用的PHP代码段

<?php echo get_post_meta( $post->ID, 'jetpack-post-views', true ); ?>

有什么想法吗?谢谢

@yamikoWebs查看错误。@Shomz添加的过滤器是第27行。我认为这只是将该片段插入该函数的正确方法的问题。有什么想法吗?嗯,这是个语法错误,所以我不这么认为。上面的线是什么?
Parse error: syntax error, unexpected T_STRING in /nfs/c08/h04/mnt/152909/domains/genesis.pixelworklab.com/html/wp-content/themes/eleven40-pro/functions.php on line 27