The result of a shortcode appear BEFORE page content

codex the_title()

replace this

$mypost .= the_title(); 

with

$mypost .= the_title('','',false); 

Leave a Comment