#84: Moving Footer into WordPress

(Updated on )

We start out by fixing up some image file paths. I always make a distinction when using images inside a WordPress theme. Is this image part of this specific theme? Or would it make sense to use in any theme for this site? If it’s for the specific theme, the image belongs in the theme folder somewhere. If it would make sense for any theme, it should be referenced from somewhere more globally useful, like an images folder at the web root.

To reference an image (or any resource) from HTML, the best way to do it is to use the bloginfo() function to get the current URL of the theme folder. Like this:

<img src="<?php bloginfo('template_url'); ?>/images/image.png" alt="">

We activate a few plugins that we had turned off when we did the database moving stuff while setting up WordPress. We might as well have (almost) the exact set of plugins activated locally as we do live. The exception being some caching stuff and backup stuff.

Moving the footer over is wicked easy, because it’s just a static chunk of HTML. We move it from our static footer.php file to our WordPress footer.php file and call it done.