0

call_user_func_array() expects parameter 1 to be a valid callback, function 'add_search_form' not found or invalid function name in /home2/zeonu81d/public_html/wp-includes/class-wp-hook.php

Please help

9
  • Like the error says, add_search_form() isn't a function. If you are trying to place a search form use get_search_form() instead.
    – Abhik
    Apr 26 '21 at 7:34
  • Can you suggest how to do it
    – Brand mgr
    Apr 26 '21 at 7:45
  • 1
    Somewhere in your code you have add_action( <something>, 'add_search_form' ); or add_filter( <something>, 'add_search_form' );. You need to find that line of code and work out what it was trying to do, because as Abhik says the add_search_form function doesn't exist and you have a hook trying to call it. Search all of your files - WordPress core, plugins and themes - for 'add_search_form' e.g. using grep.
    – Rup
    Apr 26 '21 at 7:54
  • not working I have tried
    – Brand mgr
    Apr 26 '21 at 8:14
  • Show us the code where you are suspecting the error is coning from.
    – Abhik
    Apr 26 '21 at 8:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.