I’ve been using local wp for a year now. Yesterday, i was showing the progress to my client through live link option. After showing him i tried to refresh the page with new changes i had made a few minutes after the online meeting.
Right now, i can access the website because i’m having a Fatal Error: Uncaught TypeError: Cannot access offset of type string in (…)
I know the elementor plugin is responsible for this error, i’ve tried to rollback versions, delete the plugin and reinstall it…Nothing worked.
I’m also awared that this is a local WP community and not a elementor one but I really need support and elementor only helps if you’re pro.
System Details
Local Version: Version 9.0.4+6699
Operating System (OS) and OS version: Windows 11 Pro 23H2
Local Logs
local-logs.zip (82.7 KB)
Nick-B
June 28, 2024, 2:12pm
2
Hi @FranciscoAbreu
It could be a conflict with another plugin or theme. So you could also try deactivating everything and see if that works, or try swapping out the theme. If you can’t get into the backend you can use Open Site Shell in your Local app to spin up a shell window and do CLI commands like this:
wp plugin deactivate --all
If you just deactivated and deleted the Elementor plugin from the WordPress dashboard, you might also check in your site files if it left anything behind. There could still be a configuration folder or something lingering so that it’s not fully gone.
Hi @Nick-B ,
Thank you for your help. I’ve tried to swap themes and the error persists. I deactivated all of the plugins and only when i have elementor plugin on the error triggers. When i deleted the elementor plugin, there was nothing left
I don’t really understand the reason for this error but it all started when i tried to live link.
Nick-B
June 28, 2024, 2:30pm
4
With Elementor removed from the site could you try exporting it into a zip, deleting it from Local, and then reimporting it again?
just did that, should i try to install elementor now?
it keeps showing the same fatal error on line 242
And this is the code where the error triggers on base.php
protected function get_saved_assets_data() {
$assets_data = get_option( self::ASSETS_DATA_KEY, );
$content_type = $this->content_type;
$assets_category = $this->assets_category;
if ( ! isset( $assets_data[ $content_type ] ) ) {
$assets_data[ $content_type ] = [];
}
if ( ! isset( $assets_data[ $content_type ][ $assets_category ] ) ) {
$assets_data[ $content_type ][ $assets_category ] = [];
}
return $assets_data;
}
Nick-B
June 28, 2024, 4:39pm
9
I checked with our team and @nickc noted that Elementor has a bug report here with some suggested fixes threaded that might be worth trying:
opened 04:43PM - 03 Jul 23 UTC
bug
type/responsive
product/pro
documents
mod*
theme-builder/header-template
document/assets
mod/b*
### Prerequisites
- [X] I have searched for similar issues in both open and c… losed tickets and cannot find a duplicate.
- [X] The issue still exists against the latest stable version of Elementor.
### Description
After creating a simple header template and setting its display conditions to "Entire Site", something seems to be crashing:
`Fatal error: Uncaught TypeError: Cannot access offset of type string on string in C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php:242`
For full stacktrace see attached system info.
I encountered this error for the second time now. I asked the support about the first error and they could not help. I am just experimenting with a fresh new site, so I created a completely new local (localwp.com) environment and installed only elementor and elementor pro plugins. After creating a couple of pages and a "main menu" in wordpress, I created a header template and the same fatal error shown above occured again.
Running Elementor -> tools -> "Regenerate Files & Data" a couple of times temporarily "fixes" the problem. "Fatal error" is not displayed, but on my mobile the menu is broken:
<img src="https://github.com/elementor/elementor/assets/48349588/aad7e98a-905b-42f1-9866-cd6460001e09" width=50% height=50%>
This is of course not the case in the responsive view in Elementor.
After some time the "fatal error" just comes back, I'm not sure if it happens because I edit the header template again or because I ran "Regenerate Files & Data" again. Running "Regenerate Files & Data" a couple of times also seems to temporarily fix the broken burger menu an my mobile.
To be completely fair, I also should mention that I exported Site Settings (Global Colors, Global Fonts, Theme Style settings, Layout Settings, Lightbox Settings, Background Settings) from my site where the error occured for the first time and imported these site settings into the fresh environment where I encountered the same error again now.
I'm a new user of Elementor Pro and wordpress, so far it's amazing, but this error really sets me off, please help.
Larger backtrace:
```
PHP: 2023-07-03 18:03:25 [error X 2][C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php::242] Uncaught TypeError: Cannot access offset of type string on string in C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php:242
Stack trace:
#0 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php(338): Elementor\Core\Page_Assets\Data_Managers\Base->get_saved_assets_data()
#1 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1224): Elementor\Core\Page_Assets\Data_Managers\Base->__construct()
#2 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1166): Elementor\Widget_Base->get_widgets_css_data_manager()
#3 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1219): Elementor\Widget_Base->get_widget_css()
#4 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(624): Elementor\Widget_Base->print_widget_css()
#5 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(750): Elementor\Widget_Base->render_content()
#6 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Widget_Base->print_content()
#7 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(1354): Elementor\Element_Base->print_element()
#8 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Element_Base->print_content()
#9 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\base\document.php(1711): Elementor\Element_Base->print_element()
#10 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\documents\theme-document.php(418): Elementor\Core\Base\Document->print_elements(Array)
#11 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\frontend.php(1179): ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document->print_elements_with_wrapper(Array)
#12 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\frontend.php(1074): Elementor\Frontend->get_builder_content(67)
#13 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\class-wp-hook.php(308): Elementor\Frontend->apply_builder_in_content('Allgemeiner Deu...')
#14 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\plugin.php(205): WP_Hook->apply_filters('Allgemeiner Deu...', Array)
#15 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\post-template.php(255): apply_filters('the_content', 'Allgemeiner Deu...')
#16 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\module.php(190): the_content()
#17 [internal function]: Elementor\Modules\PageTemplates\Module->print_callback()
#18 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\module.php(207): call_user_func(Array)
#19 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\templates\canvas.php(38): Elementor\Modules\PageTemplates\Module->print_content()
#20 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\template-loader.php(106): include('C:\\Users\\alex\\L...')
#21 C:\Users\alex\Local Sites\adfc\app\public\wp-blog-header.php(19): require_once('C:\\Users\\alex\\L...')
#22 C:\Users\alex\Local Sites\adfc\app\public\index.php(17): require('C:\\Users\\alex\\L...')
#23 {main}
thrown [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
```
### Steps to reproduce
1. Create a completely new wordpress + elementor pro environment using localwp
2. Add a couple of pages
3. Create a menu in wordpress
4. Create header template in elementor, add some style
5. Add wordpress menu widget to header, choose the created menu.
### Isolating the problem
- [X] This bug happens with only Elementor plugin active (and Elementor Pro).
- [X] This bug happens with a Blank WordPress theme active ([Hello theme](https://wordpress.org/themes/hello-elementor/)).
- [X] I can reproduce this bug consistently following the steps above.
### System Info
<details>
<summary>System Info</summary>
````txt
== Server Environment ==
Operating System: WINNT
Software: Apache/2.4.43 (Win32) mod_fcgid/2.3.9a
MySQL version: MySQL Community Server - GPL v8.0.16
PHP Version: 8.1.9
PHP Memory Limit: 256M
PHP Max Input Vars: 4000
PHP Max Post Size: 1000M
GD Installed: Yes
ZIP Installed: Yes
Write Permissions: All right
Elementor Library: Connected
== WordPress Environment ==
Version: 6.2.2
Site URL: http://adfc.local
Home URL: http://adfc.local
WP Multisite: No
Max Upload Size: 300 MB
Memory limit: 40M
Max Memory limit: 256M
Permalink Structure: /%postname%/
Language: en-US
Timezone: Europe/Berlin
Admin Email: **************
Debug Mode: Inactive
== Theme ==
Name: Hello Elementor
Version: 2.7.1
Author: Elementor Team
Child Theme: No
== User ==
Role: administrator
WP Profile lang: en_US
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36
== Active Plugins ==
Elementor
Version: 3.14.1
Author: Elementor.com
Elementor Pro
Version: 3.14.1
Author: Elementor.com
== Must-Use Plugins ==
Local WP Live Link Helper
Version: 2.0
Author: Flywheel
== Elements Usage ==
header : 1
container : 2
nav-menu : 1
text-editor : 1
theme-site-logo : 1
wp-page : 7
container : 8
heading : 1
text-editor : 7
== Settings ==
cpt_support: post, page
allow_tracking: yes
font_display: swap
== Features ==
Custom Fonts: 0
Custom Icons: 0
== Integrations ==
== Elementor Experiments ==
Optimized DOM Output: Active by default
Improved Asset Loading: Active by default
Improved CSS Loading: Active by default
Inline Font Icons: Inactive by default
Accessibility Improvements: Active by default
Additional Custom Breakpoints: Active by default
admin_menu_rearrangement: Inactive by default
Flexbox Container: Active
Upgrade Swiper Library: Active by default
Grid Container: Inactive by default
Default to New Theme Builder: Active by default
Hello Theme Header & Footer: Active by default
Editor Top Bar: Inactive by default
Landing Pages: Active by default
Nested Elements: Inactive by default
Nested Accordion: Inactive by default
Lazy Load Background Images: Inactive by default
Global Style Guide: Inactive by default
Page Transitions: Active by default
Notes: Active by default
Loop: Active by default
Form Submissions: Active by default
Scroll Snap: Active by default
Menu: Inactive by default
== Log ==
PHP: showing 4 of 4PHP: 2023-07-03 18:01:59 [notice X 1][C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php::242] Automatic conversion of false to array is deprecated [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
PHP: 2023-07-03 18:02:09 [error X 5][C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php::242] Uncaught TypeError: Cannot access offset of type string on string in C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php:242
Stack trace:
#0 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php(338): Elementor\Core\Page_Assets\Data_Managers\Base->get_saved_assets_data()
#1 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1224): Elementor\Core\Page_Assets\Data_Managers\Base->__construct()
#2 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1166): Elementor\Widget_Base->get_widgets_css_data_manager()
#3 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1219): Elementor\Widget_Base->get_widget_css()
#4 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(624): Elementor\Widget_Base->print_widget_css()
#5 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(750): Elementor\Widget_Base->render_content()
#6 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Widget_Base->print_content()
#7 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(1354): Elementor\Element_Base->print_element()
#8 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Element_Base->print_content()
#9 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\base\document.php(1711): Elementor\Element_Base->print_element()
#10 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\documents\theme-document.php(418): Elementor\Core\Base\Document->print_elements(Array)
#11 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\frontend.php(1179): ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document->print_elements_with_wrapper(Array)
#12 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\base\document.php(1155): Elementor\Frontend->get_builder_content(67, false)
#13 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\library\documents\library-document.php(76): Elementor\Core\Base\Document->get_content(false)
#14 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\documents\theme-document.php(158): Elementor\Modules\Library\Documents\Library_Document->get_content(false)
#15 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\documents\theme-document.php(173): ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document->get_content()
#16 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\classes\locations-manager.php(315): ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document->print_content()
#17 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\api.php(13): ElementorPro\Modules\ThemeBuilder\Classes\Locations_Manager->do_location('header')
#18 C:\Users\alex\Local Sites\adfc\app\public\wp-content\themes\hello-elementor\header.php(35): elementor_theme_do_location('header')
#19 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\template.php(783): require_once('C:\\Users\\alex\\L...')
#20 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\template.php(718): load_template('C:\\Users\\alex\\L...', true, Array)
#21 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\general-template.php(48): locate_template(Array, true, true, Array)
#22 C:\Users\alex\Local Sites\adfc\app\public\wp-content\themes\hello-elementor\index.php(15): get_header()
#23 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\template-loader.php(106): include('C:\\Users\\alex\\L...')
#24 C:\Users\alex\Local Sites\adfc\app\public\wp-blog-header.php(19): require_once('C:\\Users\\alex\\L...')
#25 C:\Users\alex\Local Sites\adfc\app\public\index.php(17): require('C:\\Users\\alex\\L...')
#26 {main}
thrown [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
PHP: 2023-07-03 18:03:23 [warning X 1][C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\common\modules\ajax\module.php::175] Undefined array key "data" [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
PHP: 2023-07-03 18:03:25 [error X 2][C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php::242] Uncaught TypeError: Cannot access offset of type string on string in C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php:242
Stack trace:
#0 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\page-assets\data-managers\base.php(338): Elementor\Core\Page_Assets\Data_Managers\Base->get_saved_assets_data()
#1 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1224): Elementor\Core\Page_Assets\Data_Managers\Base->__construct()
#2 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1166): Elementor\Widget_Base->get_widgets_css_data_manager()
#3 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(1219): Elementor\Widget_Base->get_widget_css()
#4 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(624): Elementor\Widget_Base->print_widget_css()
#5 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\widget-base.php(750): Elementor\Widget_Base->render_content()
#6 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Widget_Base->print_content()
#7 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(1354): Elementor\Element_Base->print_element()
#8 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\base\element-base.php(449): Elementor\Element_Base->print_content()
#9 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\core\base\document.php(1711): Elementor\Element_Base->print_element()
#10 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor-pro\modules\theme-builder\documents\theme-document.php(418): Elementor\Core\Base\Document->print_elements(Array)
#11 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\frontend.php(1179): ElementorPro\Modules\ThemeBuilder\Documents\Theme_Document->print_elements_with_wrapper(Array)
#12 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\includes\frontend.php(1074): Elementor\Frontend->get_builder_content(67)
#13 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\class-wp-hook.php(308): Elementor\Frontend->apply_builder_in_content('Allgemeiner Deu...')
#14 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\plugin.php(205): WP_Hook->apply_filters('Allgemeiner Deu...', Array)
#15 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\post-template.php(255): apply_filters('the_content', 'Allgemeiner Deu...')
#16 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\module.php(190): the_content()
#17 [internal function]: Elementor\Modules\PageTemplates\Module->print_callback()
#18 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\module.php(207): call_user_func(Array)
#19 C:\Users\alex\Local Sites\adfc\app\public\wp-content\plugins\elementor\modules\page-templates\templates\canvas.php(38): Elementor\Modules\PageTemplates\Module->print_content()
#20 C:\Users\alex\Local Sites\adfc\app\public\wp-includes\template-loader.php(106): include('C:\\Users\\alex\\L...')
#21 C:\Users\alex\Local Sites\adfc\app\public\wp-blog-header.php(19): require_once('C:\\Users\\alex\\L...')
#22 C:\Users\alex\Local Sites\adfc\app\public\index.php(17): require('C:\\Users\\alex\\L...')
#23 {main}
thrown [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
== Elementor - Compatibility Tag ==
Elementor Pro: Compatible
== Elementor Pro - Compatibility Tag ==
````
</details>
1 Like
I have to thank you Nick! the suggestion of recreating/regenerating elementor CSS files (elementor > tools > general > recreate/regenerate CSS and data) worked perfectly. This is an odd error with such a easy fix. My mind was going crazy lol Thank you
2 Likes
Nick-B
June 28, 2024, 7:00pm
11
When I saw that in there I was thinking surely it’s not that simple? If only more things were that easy
1 Like
system
Closed
June 30, 2024, 7:01am
12
This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.