Kicking it Off With Kirby

My relationship with Stacy didn’t last long once I tried to add preformatted code beyond simple HTML. I didn’t have the time to fix the parsing errors. I had to find an aletrnative and it had to meet my simple taste for a CMS. I wanted the following:

Problems with Stacy

I had to cut it off between me and Stacy. The deal breaker was the lack of support for preformatted text. The quick solution was to create Github Gists for every piece of code, but that just became ridiculous. I seemed to over-look a lot of Stacy’s flaws because it was free.

And Then There Were Two

The choices came down to two premium no-database CMS’s, Statamic and Kirby. Statamatic had some very popular users behind it, with mostly the same structure as Stacy and Kirby. Though, it wasn’t open sourced.

Kirby hosts all of the code on Github, with some contributions from individual developers. I was going with Kirby mostly because of the github community.

The payment structure was similar to Sublime Text 2, you can technically use it indefinitely with all the features for free, but the license requires a purchase to use it. The $39 would be an investment and more of a thank you to the developer.

Making the Switch to Kirby

Installing Kirby was easy. Mac OS X comes with PHP and Apache pre-installed so it was only a few steps to get local development going.

Open a browser with http://localhost/ and everything was mostly working. You need to change your URL and Subfolder values within the site\config\config.php file, but if you change templates, Kirby will give you instructions within the browser on what to change. If you keep the default template, this post on installing Kirby will help you complete setup. I’m starting out with Monochrome for now.

Baby Steps

I’m going to walk through the first few steps I took to get up and running. First, let’s upgrade to a more robust Markdown parser.

Change it to this:

c::set('markdown.extra', true);

Next up, a few changes to the header.php file.

<!doctype html>
<html itemscope itemtype="">

Change the first few lines to the following:

<!DOCTYPE html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9" lang="en"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" itemscope itemtype=""> <!--<![endif]-->

Lastly, I added Modernizr for good measure. Add a PHP script tag right before the closing head tag.

<!-- Modernizr -->
<?php echo js('assets/js/modernizr-2.6.2.min.js') ?>

Configure your Modernizr build however you want, I usually just stick to the CSS3 detection, a few of the HTML5 and leave it at that. The rest is overkill.

That was it for getting this site going. Kirby is for the most part pretty modern and has plenty of good starter templates. This site is now running Kirby.