Using a very easy single line method , let’s see how we can call shortcode into our wordpress template using php code. Usually , the shortcode are used by the plugin developers to accomplish certain task with minimal code effort to display.
A shortcode is a WordPress-specific code that lets you do nifty things with very little effort. Shortcodes can embed files or create objects that would normally require lots of complicated, ugly code in just one line.
Simple PHP function
do_shortcodecan do the trick. Here is the magic line.
<?php echo do_shortcode('[your_shortcode]'); ?>