Wordcraft, a simple PHP blogging application

Thu, Nov 6, 2008 08:00 AM

So, a while back, not sure when, I was listening to the P3 Podcast and Paul mentioned his dislike for Wordpress.  He said he wished there was a simple blogging application.  I am probably misquoting him horribly.  It was an idea that I had been tinkering with.  So, I started on Wordcraft in my spare time.  Like super spare time.  That time between the kids going to bed and me falling  asleep.  So, it took a while to get it to a usable state.

Up until now, I have used Wordpress.com for my blogging.  It works quite well.  You can get started quite quickly and it does what most people need.  My wife uses Blogger for our family blog.  It is, IMO, not as nice as Wordpress.com in some ways.  But, it does allow you to edit your styles (for free) and such which is nice.

So, why would I want to reinvent the wheel?  I am a control freak and rarely run other people's code.  I know, it is a character flaw.  I am working on it.  So, what did I come up with?

I had some goals when I started on this.

  1. Keep it simple.
  2. Focus on what I am good at doing.

Keeping it simple

I use MySQL.  I didn't try to make it work with every possible database.  In fact, it only uses the mysqli PHP extenstion.  The few objects (CAPTCHA) are all PHP 5 objects.  I don't plan to worry about PHP 4.  The templates don't use a template language.  They use plain old PHP.  The are scoped to protect template authors from global scope.  There are only 6 files required to make a new template.  There are just 589 lines of code in the forward facing scripts.  The admin has 2,446.

What am I good at doing?

I write PHP/MySQL code that has to work fast for a living.  It is what I get paid to do.  I am not a designer.  I am not a spam catching wizard.  I don't write cool javascript widgets.  So, I focused on the PHP/MySQL parts of the code.  For templates, I used designs that are released under the Creative Commons license.  I use Akismet and the CAPTCHA libraries from Phorum for spam catching.  I used the YUI Rich Editor for the admin where I needed a WYSIWYG widget.  I even link to the YUI sources that are hosted by Yahoo.  No sense taking on that bandwidth or storage.

So, what does it do you ask?  Well, here are some of the features:

  • WYSIWYG editing via YUI.
  • Comments with optional CAPTCHA and/or Akismet.
  • Custom pages can be created.
  • Tagging of posts
  • Custom publish dates
  • Automatic Pingback support
  • Friendly URL support with mod_rewrite
  • 5 Templates in first release.  Easy to build more.
  • Email notifications to authors

There are some things missing of course.  Internationalization of both the admin and templates is a big one.  There is no current search engine for blog posts.  There is no "blog roll" type of feature.  There is no date based archive.  And I am sure there is more missing.  And I am sure there are bugs.

But, if you would like to try out yet another PHP application, I welcome you to give it a try.  The code is hosted at Google Code.  It is a BSD licensed application.

Gravatar for Bert Garcia

Bert Garcia Says:


Downloaded the code, cause I'm a huge fan of small code bases.

Will give it a try this afternoon, just read the install docs (#7 needs fixing).

Thanks for sharing.

Gravatar for mike

mike Says:

I'll have to take a look too. You sound a lot like me. Keep it simple, screw legacy code, etc.

Gravatar for Brian Moon

Brian Moon Says:

.5 is eminent. And SVN checkout may be better if you just want to play with it. Just as I found with Phorum, the best way to find bugs is to use the software. I have 10+ commits today alone. This site is running SVN basically. At this point, it is still ahead of SVN actually.

Gravatar for Roman

Roman Says:

are there is multilingual?

Gravatar for gigi

gigi Says:

Yet again another pile-o-crap application based on a pile-o-crap database.

I bet you don't even have any database abstraction layer. Not that it would make sense to have one for a three bytes application.

Gravatar for Brian Moon

Brian Moon Says:

@Roman, no, not at this time.

@gigi, geez, who messed up your world today? If you have no interest, just move along please.

Gravatar for Roman

Roman Says:

how to translate? in a single file (like WP) or rewrite all? I just want to translate Wordcraft into Russian, he was interested me.


Gravatar for Brian Moon

Brian Moon Says:

The templates are just all created with English. The admin is as well. I have plans to convert the admin and templates over to a system like Phorum uses. But, I have not gotten to that step yet. I have been focused on the PHP/MySQL parts of the application.

Gravatar for jack

jack Says:

why not using wordpress instead?

Gravatar for Roman

Roman Says:

Brian, if you do support Russian language later - let me know. I help you :)

Comments are disabled for this post.