WP 4.7 Breaks ‘(updated) Move the featured pages’ Snippet
-
Hello!
I am using this snippet, updated from the comments Oct 2016:
https://presscustomizr.com/snippet/move-featured-pages-block-anywhere-front-page/
(actual code copied from my child functions.php)
//we hook the code on the wp_head hook, this way it will be executed before any html rendering. add_action ( 'wp_head' , 'move_my_fp'); function move_my_fp() { //we unhook the featured pages remove_action ( '__before_main_container', array( CZR_featured_pages::$instance , ‘czr_fn_fp_block_display’), 10 ); //we re-hook the block. Check out the priority here : set to 0 to be the first in the list of different actions hooked to this hook add_action ( '__after_main_container', array( CZR_featured_pages::$instance , ‘czr_fn_fp_block_display’), 0 ); }
And after the new WordPress update I get:
Warning: call_user_func_array() expects parameter 1 to be a valid callback, class 'CZR_featured_pages' does not have a method '‘czr_fn_fp_block_display’' in /home/xxx/xxx/xxx/wp-includes/class-wp-hook.php on line 298
I am totally ignorant of PHP, can anyone spot what is wrong and correct the code?! The comments section is shut on the relevant snippets page unfortunately!
THANKS SO MUCH!!
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘WP 4.7 Breaks ‘(updated) Move the featured pages’ Snippet’ is closed to new replies.