Shortcodes in templates
If you are using shortcodes, you might want to add them in a template page instead of in the content of a page or post. Luckily, WordPress has a function for this;
You can add this anywhere you want your shortcode.
<?php echo do_shortcode("[my_shortcode]"); ?>
Show Images from Post or Page Attachments List subpages and siblings Check if last post Members Only Content Shortcode Dynamic custom length excpert Only show the authors posts in the edit list Avoid Duplicate Posts in Multiple Loops Display total number of comments Facebook Share outside loop Disable top-level menus from Admin Panel 2