2 min read

WordPress: A Complete CMS

My entire site is now managed by WordPress. It took a bit of research and held a couple of challenges but overall was not too bad. I’ll highlight some of the more difficult parts of the migration below –

Maintaining Link Structure
Since WordPress previously acted solely as my blogging platform (it resided under the ‘blog’ directory of our site), one of the important pieces to the puzzle was to ensure that each post still maintained its link structure. I needed to make sure that moving WordPress to my root directory would not disturb any links pointing to specific posts. For example, someone linking to a post with permalink ‘http://kenyarmosh.com/post-name’ should be able to access the post at the same exact location.

After moving WordPress to the root level, I accomplished this by simply leveraging the template tag of our permalinks to create a virtual site structure for the blog. That is, I allowed WordPress to use the Apache mod_rewrite() function to essentially pretend that my posts resided under a directory called ‘blog’. This structure became ‘/blog/%postname%/’ (you can edit this particular element under the ‘Options -> Permalinks’ WordPress administration area).

Static Pages
A page exists outside of a blog – take for example, our About page. Pages are what allow WordPress to act as an actual CMS.

One neat trick I learned some time ago was that WordPress allows multiple page templates. The standard ‘page.php’ is the default template WordPress uses whenever a static ‘page’ is created. By creating other page templates, however, you can specify which page template you want to use when creating the page. My Consulting, Training, and FAQ pages actually all share one page template called ‘services.php’. Below you can see how to select your page template

Page Template Selection

Home Page
The final challenge was to get a home page that wasn’t the blog itself. Every design template contains an ‘index.php’, which by default is the first “page” rendered by browsers. Promoting WordPress to the root web directory meant that visitors to my site would first encounter my blog. I didn’t want that.

There are actually two ways to approach this problem. The first is to create a ‘home.php’ page template file and then create a ‘Home’ page using that particular template. Unfortunately, that did not work for me – at some point, I’ll probably revisit why. The second (and perhaps easier) way is to use a plug-in. I choose Denis de Bernardy’s Static front page plug-in to get the job done. For reference sake, I also found this thread on WordPress to be quite informative.

The result is a completely managed WordPress site – well worth the effort!

update: An old post of Phu Ly helped me see the light on the ‘home.php’ issue (missed one line of code using the ‘query_post’ function). I have deactivated and removed the static front page plug-in. Not that I didn’t like it, just wanted a cleaner implementation.

Join thousands reading my insights on remote strategy, leadership, & operations.