PHP based real-time dynamic-site-generator. Browse the code on GitHub  Demo

So, on Jul 22, 2016 I started off with a small project that I had been meaning to develop for quite some time. As Jekyll becomes increasingly popular, more and more people are choosing to migrate from WordPress and alternatives to Jekyll. I read Raymond Camden’s post on this matter, and decided to take a look at the tool.

I showed it to my friend, Amin Eftegarie, because it reminded me of something I had tried to build years ago. Dubbed “QuickSites”, it had been my first attempt at creating something of a database-less CMS. It was basically a dynamic website written in PHP that got page content from static files. It has always been there on my GitHub. It wasn’t the most friendly, and it was pretty barebones, and the demo I setup for it wasn’t exactly the most aesthetic.

So, while talking to Amin I realized that there was still sufficient room on the web for a PHP based dynamic-site-generator that, in terms of content creation, offered the same experience as jekyll, but didn’t require you to run a command and generate a static site and deploy it every time you choose to make a small change. And that’s how Danvers was born. Obviously I had decided to use QuickSites as something of a codebase so as to avoid “coders block,” and it felt both stupid and cool to be the first one to fork and create something new using my own code. I also decided to name the final product after a character from “The strange case of Dr. Jekyll and Mr. Hyde.”

Since I wanted to offer the same user-experience as jekyll, I checked out its documentation, and soon had a plan. It had to have separate pages for different types of contents, it had to offer blogging, it had to have author and category archives and permalinks and comments for posts, and it had to allow for posts and pages to be created using markdown, textile and HTML.

At exactly 5:21 I had made my first commit. I started off with the blog module, and then I added markdown and textile support. Posts need to be named using the same convention as jekyll, and for categories and authors, post files need to have frontmatter. Instead of using LiquidJS or YAML, I decided to define my own tags, and there’s a number of them and the frontmatter is just one of their uses. The very last feature I added was the comments module.

The design end is more or less identical to what quicksites offered. There’s a themes folder and you need to edit a file to change the theme. But there has been a slight addition to the number of required files. There are a number of template files, like for the singlepost pages or for comment forms, and they use certain tags to define where the dynamically loaded content should be present, but it is all very intuitive.

By Jul 30, I was done. On August 5, I created a small Wiki to serve as a “Getting Started” guide. I named it Danvers as it was like the only name from the novel that hadn’t already been used for  a jekyll alternative.


Anas Ismail Khan


Leave a Reply

Your email address will not be published. Required fields are marked *