save_post hook is not called when post is saved
A quick way of debugging the save function before redirection – is to die(print_r($post_id)); // or var_dump($post_id); this will stop all PHP from continuing and is fast for small debugging where you don’t need an entire log. throw that into your function, and see what happens in it – change the variable to see if … Read more