首页 文章

更新wordpress时出现致命错误

提问于
浏览
0

我将avada更新为5.0并遇到了子主题的问题 . 有人可以帮助我一秒钟吗?

致命错误:在第222行的/home/manekine/public_html/wp-content/themes/Avada-Child-Theme/header.php中调用未定义的函数avada_is_portfolio_template()

网站是:http://www.manekinekocasino.com

这是第222行,其中错误来自:

if ( is_page_template( '100-width.php' ) 
     || is_page_template( 'blank.php' ) 
     || ( '1' == fusion_get_option( 'portfolio_width_100', 'portfolio_width_100', $c_pageID ) 
     || 'yes' == fusion_get_option( 'portfolio_width_100', 'portfolio_width_100', $c_pageID ) && ( 'post' == get_post_type( $c_pageID ) 
     || 'avada_portfolio' == get_post_type( $c_pageID ) ) ) 
     || ( avada_is_portfolio_template() && 'yes' == get_post_meta( $c_pageID, 'pyre_portfolio_width_100', true ) ) 
     || '100-width.php' == $page_template ) 
{
    $main_css = 'padding-left:0px;padding-right:0px;';

1 回答

  • 0

    他们可能已经重命名了该功能,或者如果它在更新之前正常工作就将其删除 . 了解答案的最佳方式是与他们的开发人员取得联系 . 您可以在调用之前检查该功能是否存在 . 不是最好的方法,但你摆脱了错误:

    if ( is_page_template( '100-width.php' ) 
     || is_page_template( 'blank.php' ) 
     || ( '1' == fusion_get_option( 'portfolio_width_100', 'portfolio_width_100', $c_pageID ) 
     || 'yes' == fusion_get_option( 'portfolio_width_100', 'portfolio_width_100', $c_pageID ) && ( 'post' == get_post_type( $c_pageID ) 
     || 'avada_portfolio' == get_post_type( $c_pageID ) ) ) 
     || (function_exists('avada_is_portfolio_template') && avada_is_portfolio_template() && 'yes' == get_post_meta( $c_pageID, 'pyre_portfolio_width_100', true ) ) 
     || '100-width.php' == $page_template ) 
    {
          $main_css = 'padding-left:0px;padding-right:0px;';
    

相关问题