WordPress – Inserting shortcode outside the loop in a template

Shortcodes were properly introduced back in WordPress 2.5 – they are usually used in the post content area for doing all sorts of cool things, both with core code and [gs plugin]s… but what if you need to call a shortcode OUTSIDE of a post (loop) in your template?

You insert WordPress shortcodes like this [shortcode option1="value1" option2="value2"] into your main content area- but if you want to use WordPress shortcode outside of the loop in your template use the following PHP:

<?php echo do_shortcode('[shortcode option1="value1" option2="value2"]'); ?>
SOURCE

LINK (Wp-cms.com)

LANGUAGE
ENGLISH