Solved

How to solve this Uncaught TypeError

  • 25 November 2021
  • 3 replies
  • 20 views

Badge +1

 My website is completely black. If I try to open the Elementor editor, it only works in Safe Modus. If I go to the debugger, this is the error I get. Anyone any ideas how to fix it?

Uncaught TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, function "my_scripts_method" not found or invalid function name in /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php:303Stack trace:#0 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters(NULL, Array)#1 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/plugin.php(470): WP_Hook->do_action(Array)#2 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/script-loader.php(2083): do_action('wp_enqueue_scri...')#3 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php(303): wp_enqueue_scripts('')#4 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters(NULL, Array)#5 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/plugin.php(470): WP_Hook->do_action(Array)#6 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/general-template.php(3015): do_action('wp_head')#7 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-content/plugins/elementor-pro/modules/theme-builder/views/theme-support-header.php(21): wp_head()#8 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-content/plugins/elementor-pro/modules/theme-builder/classes/theme-support.php(72): require('/customers/5/d/...')#9 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php(305): ElementorPro\Modules\ThemeBuilder\Classes\Theme_Support->get_header(NULL)#10 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters('', Array)#11 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/plugin.php(470): WP_Hook->do_action(Array)#12 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/general-template.php(38): do_action('get_header', NULL, Array)#13 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-content/plugins/elementor/modules/page-templates/templates/header-footer.php(9): get_header()#14 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-includes/template-loader.php(106): include('/customers/5/d/...')#15 /customers/5/d/7/anneleenvaes.be/httpd.www/wp-blog-header.php(19): require_once('/customers/5/d/...')#16 /customers/5/d/7/anneleenvaes.be/httpd.www/index.php(17): require('/customers/5/d/...')#17 {main}  thrown
icon

Best answer by Anneleen Vaes 28 November 2021, 17:04

View original

3 replies

Userlevel 7
Badge +4

@Anneleen Vaes Have you found your answer yet? If so, please share it here so we can mark your answer as the best one and help others who may have a similar question, thanks :)

Badge +1

I just switched the theme, that was the big cause. But would have been better to just fix the error within that specific theme.

Userlevel 7
Badge +4

@Anneleen Vaes Not all themes will be able to work with Elementor or perhaps are not kept up to date as Elementor updates, so that could have been the cause. What theme were you using and what did you switch to?

 

If you have Elementor Pro, as I see you do then you can build everything with it (using theme builder) including the site parts that a theme normally provides (e.g. archive pages, single post, header, footer) and then use Elementor Hello theme which is a bare bones theme that is very lightweight and meant for Pro.

 

Anyway, glad you got it sorted out.

 

Reply