Forum breadcrumbs – You are here:Asgaros Support ForumSupportHook don't work
Please or Register to create posts and topics.

Hook don't work

Hello. I add
add_filter( ‘asgarosforum_after_add_post_submit’, ‘add_post_forum’,2,2 );

but my function don’t start. Why it can be?

Hello Romeo,

you called the filter-function, but it is not a filter. So you have to use add_action(…) instead.

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!
Quote from Asgaros on October 30, 2017, 8:08 am

Hello Romeo,

you called the filter-function, but it is not a filter. So you have to use add_action(…) instead.

add_action don’t work too

Have you added it to the correct place? Is the function not called or is the code inside not working?

Also keep in mind that this hook is only fired when a new answer is created – not during the creation of a new topic.

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!

I add it in function.php. It’s work some times ago(before I updated forum).

function is no calling at all. if I change it to asgarosforum_after_post_message, then my function is calling well

Can you please show me the full code of your function?

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!