Shortcodes work in post and page's content, but when you paste them into the theme code, they are not interpreted / converted into the actual thing. Now what do we do?

Easy. Just use the do_shortcode() function:

PHP Code:
<?php echo do_shortcode("[example_shortcode]"); ?>
That's it!