Wordpress Elementor Pro发布更新错误



Iv最近收到了下面的错误,Iv尝试逐一更新我的插件和主题,但问题似乎是在将elementor或wordpress更新到最新版本后发生的。我不知道该怎么做才能解决这个问题,目前我正在重新保存更新前的备份以添加新内容。Iv最近停止为elementorpro付费,并开始使用免费版本,这当然会解决这个问题吗?

致命错误:Uncaught ReflectionException:方法get_site_editor_type不存在于/home/customer/www/catalystcenter.com.au/public_html/wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php中:45堆栈跟踪:#0/home/client/www/catalystcenter.au/public_html/wp-content/plugins/elementorpro/modules/theme-builder-documents.php(45(:反射类->getMethod('get_site_editor…'(#1/home/customer/www/catalystcentral.com.au/public_html/wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php(126(:ElementorPro\modules\ThemeBuilder\documents/theme_document::get_site_editor_type_bc(94(:ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document::get_create_url((#3/home/customer/www/catalystcenter.com.au/public_html/wp-content/plugins/elementor/core/common/Modules/finder/categories/create.php

解决方案1:

您也可以简单地注释掉/wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php中的行。第46行为

$method = $reflection->getMethod( 'get_site_editor_type' );

解决方案2:

替换theme-document.php中的代码

$reflection = new ReflectionClass( $class_name ); //45 line
$method = $reflection->getMethod( 'get_site_editor_type' );
// It's own method, use it.
if ( $class_name === $method->class ) {
return static::get_site_editor_type();
}

通过

if (method_exists($class_name, "get_site_editor_type")) {
$reflection = new ReflectionClass( $class_name );
$method = $reflection->getMethod( 'get_site_editor_type' );

// It's own method, use it.
if ( $class_name === $method->class ) {
return static::get_site_editor_type();
}
}

最新更新