You can use the remove_action()
function to unhook a function from an action and then add_action()
to hook it elsewhere. Note that when removing an action you must specify the tag (hook name), function, and priority exactly as it was added.
Edit: Here are some additional details:
You’ll have to look at the source of the other plugin to determine how to do that. Without specific information about which plugin and function you’re talking about we can’t give you an exact answer, but here’s an example:
if the plugin hooks the function like this:
add_action( 'woocommerce_before_my_account', 'function_to_move', 10 );
you would do something like:
function my_move_woo_functions() {
remove_action( 'woocommerce_before_my_account', 'function_to_move', 10 );
add_action( 'woocommerce_after_my_account', 'function_to_move', 10 );
}
add_action( 'plugins_loaded', 'my_move_woo_functions' );
The important part is that you have to move the action after their hook is created but before the hook is run.