php - Remove wordpress action inside class definition function of a theme -


i need in removing action of wordpress within public function of class. want remove old function , want define new function against it.

code looks below

function hook_link($c){ return  apply_filters('hook_link', $c);  }  class blue_themes {      public function blue_themes(){          add_action( 'hook_link', array($this, 'old') );          function old($val){ //want remove action             return $val;          }             }  } 

use function remove old function , add new function .

remove_filter('remove function name', 1); add_filter('add function name', 1); 

Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -