the_content after all shortcodes are parsed

Are you looking for a filter perhaps?

add_filter( 'the_content', 'wpse_the_content_filter', 20 );

function wpse_the_content_filter( $content ) {
   // Do whatever you want with the $content
   return $content;
}

Filtering ‘the_content’ will pass the post or page content through a function of your choice.

Just make sure to run it late (e.g. 20) and return the contents so they can be displayed.

More information here:

https://codex.wordpress.org/Plugin_API/Filter_Reference/the_content

Leave a Comment