This is the content of an article on the use of shortcodes found on wprecipes, borrowed from catswhocode.
Simply use the do_shortcode() function anywhere in your theme file. The shortcode you want to use have to be given to the function as shown below:
<!--?php do_shortcode('[galery]');?-->
This would seem to imply that to call a shortcode from a template file, you insert the above.
Unfortunately, this advice is plain wrong.
First, the correct syntax is
<!--?php echo do_shortcode('[galery]');?-->
Notice the missing echo instruction?
Further, you do not insert the word gallery, but the following parameters:
<!--?php do_shortcode('[nameofshortcode parameter1=”x” parameter2=”y”]'); ?-->;
That is you insert the name of your shortcode, followed by a space, then the names of the parameters (if any) followed by the equal sign, then the actual value of the parameter(s) in between quotes. If further parameters are required, they should be separated by a space. The last parameter has no space between the closing quote of its value and the closing square bracket.
All good and well if you are passing constants. What if you want to pass variables? After much googling about, I found out on event expresso that the syntax is:
<!--?php echo do_shortcode('[nameofshortcode parameter1="'.$myvariable.'" Parameter2="0"]');?-->
In the above example, parameter1 is a variable, while parameter2 is a constant.
I am not sure if the way the wprecipes article was written is down to lazyness or sheer incompetence.