I’ve found init and init_admin. Are there any action that executes just in the frontend?
Thanks.

4 s
4

You can combine add_action() and an is_admin() check:

! is_admin() and add_action( 'init', 'my_custom_callback' );

Now the callback function will run on front-end only.

Leave a Reply

Your email address will not be published. Required fields are marked *