Probably nowhere because it outputs too early. I recommend to use error_log
function and turn on WP_DEBUG_LOG
.
Just add to the wp-config.php
file somewhere in front of this line:
require_once(ABSPATH . 'wp-settings.php');
these new lines:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
Now create in wp-content
folder a new file debug.log
and set chmod to 640.
And this line in your code:
var_dump($post);
replace with this:
error_log( var_export( $post, true ) );
Now you will find content of the $post
variable in the debug.log
file.