Attach pdf from dynamic url
You can try to do it in two ways. The first one, much more simple, is to save a temporary PDF file somewhere, for example in a uploads directory, use it as attachment and delete if after the call to wp_mail() function is made: function my_custom_save_post( $post_id, $post, $update ) { if( ! $update ) … Read more