How to call do_action() to pass arguments to hooked functions that take different number of args?

All the additional arguments passed to do_action() are passed as arguments, in order, to any hooked callback function. The callback functions can only choose how many of them to use, by setting the $accepted_args parameter of add_action(). They can’t choose which arguments to accept. So you would need to do something like this: add_action(‘myaction’, ‘my_multiplication’, … Read more

Can we change the hook firing sequence?

It’s a bit of a hack, but you could create a new member in your $plugin_admin_listings class that’s an array of post IDs published in this page cycle in your transition_post_status add the IDs to that array in save_meta_data as you save each post check if its ID is in the published_posts array and then … Read more