修复Elementor的Fatal error: Uncaught Error: Class ‘Elementor\Scheme_Color错误

如果您使用 Elementor Page Builder 和其他与 Elementor 互补的相关插件,您可能正在处理这个致命错误。

Fatal error: Uncaught Error: Class ‘Elementor\Scheme_Color’ not found

好消息是,我们可以为您提供您需要做的确切事情,以快速修复此问题并让您的网站再次正常运行。

  1. 在 wp-content/plugins 文件夹中创建一个新的php 文件,例如fix-scheme-color.php
  2. 将下面的代码段添加到您刚刚创建的文件中,保存后前往Wordpress后台的插件页面。启用插件 Elementor Scheme_Color and Scheme_Typography Class Issue 即可。
<?php
/**
* Plugin Name: Elementor Scheme_Color and Scheme_Typography Class Issue
**/namespace Elementor;
\add_action(
  'plugins_loaded',
  function() {
    if ( ! class_exists( 'Elementor\Scheme_Color' ) ) {
      class Scheme_Color extends Core\Schemes\Color {}
    }
  }
);
\add_action(
  'plugins_loaded',
  function() {
    if ( ! class_exists( 'Elementor\Scheme_Typography' ) ) {
      class Scheme_Typography extends Core\Schemes\Typography {}
    }
  }
);
?>

本文已在Ie主题99839发布

文章来源:https://ietheme.com/fixed-fatal-error-uncaught-error-class-elementor.html


撰写评论

您的电子邮箱地址不会被公开。 必填项已用*标注

加入我们

注册完成!

密码重置

请输入您的邮箱地址。 您将收到一个链接来创建新密码。

检查你的邮件中的确认链接。