call_user_func_array error
-
Hi there,
We installed your plugin on our site and it works perfectly except that we’re getting this error:
call_user_func_array() expects parameter 1 to be a valid callback, second array member is not a valid method in wp-includes/class-wp-hook.php
I narrowed it down to this line in the plugin:
add_action( 'wp_enqueue_scripts', array( $this, self::timeline_express_print_inline_styles( $options ) ) );
Commenting that out, I got rid of the error, but of course, this function is needed so I had to find a way to work around it. Here’s what I came up with:
add_action( 'wp_enqueue_scripts', array( $this, 'timeline_express_print_inline_styles' ) ); public function timeline_express_print_inline_styles() { $timeline_express_options = timeline_express_get_options(); ... }
Is there a way for me to add this into my theme? I tried removing the action and adding it again on my own files so I don’t touch the plugin, it it doesn’t seem to be working.
Thanks!
- The topic ‘call_user_func_array error’ is closed to new replies.