Introducing Word Press

Socrates Premium Wordpress Theme

Socrates Premium Wordpress Theme

Get Instant Access

by Jeffrey Way

So, you've been messing about with websites for a little while now, and you've decided to take the plunge and learn how to design themes for WordPress. Perhaps you're a blogger yourself, and you want to take the next step by redesigning your site, or perhaps you've heard that there's a strong market for ready-made WordPress themes and you want to get in on the ground floor, so to speak. You're probably itching to start building your first WordPress theme, but before we jump in, it's a good idea to think about why we're here, and how we arrived. This chapter will give you a bit of background on WordPress in general and WordPress themes in particular.

In the following two chapters Brandon will take you through the process of planning and designing your theme; then Raena will take over and introduce you to the code behind WordPress themes and the Thematic framework, which will make your life as a developer much more enjoyable. After that, Allan will take you through the slightly more advanced topics of widgets and custom theme options; and finally, it's me again, Jeffrey, back to provide some insight into how to sell your themes and profit from them.

Here we go!

A Brief History of WordPress

Many of you may be unaware that WordPress is based on a blogging platform with a modest adoption rate—a few thousand installations—built in mid-2001 and called b2.1 Michel Valdrighi, its developer, managed development for roughly two years before the platform's users began to notice that he'd seemingly abandoned the project. Fortunately for thousands upon thousands of loyal WordPress users, one particular b2 fan was Matt Mullenweg, the creator of WordPress.

Thanks to the convenience of online archives, we can trace the inception of WordPress back to one single blog entry, made by Mullenweg on January 24th, 2003:

[...] My logging software [b2] hasn't been updated for months, and the main developer has disappeared, and I can only hope that he's okay.

What to do? Well, Textpattern looks like everything I could ever want, but it doesn't look like it's going to be licensed under something politically I could agree with. Fortunately, b2/cafelog is GPL, which means that I could use the existing codebase to create a fork, integrating all the cool stuff that Michel would be working on right now if only he was around. The work would never be lost, as if I fell of the face of the planet a year from now, whatever code I made would be free to the world, and if someone else wanted to pick it up they could. I've decided that this the course of action I'd like to go in, now all I need is a name. What should it do? Well, it would be nice to have the flexibility of MovableType (sic), the parsing of TextPattern (sic), the hackability of b2, and the ease of setup of Blogger. Someday, right?

—Matt Mullenweg

This date marks WordPress's birthday—at least in hindsight! In that short two-paragraph posting, called "The Blogging Software Dilemma," Matt sows the seed of an idea that will eventually turn into WordPress. Over the course of 2003, along with Mike Little, Matt did indeed forkb2 and prepare the first release of WordPress, which ultimately was announced on December 26th.

WordPress Today

If we leap forward six years, WordPress has now been installed over 22 million times, easily making it the most popular blogging platform in the world. Due to its extensibility, literally thousands of plugins have been built on top of the framework, allowing for increased functionality, including the handling of sites like job boards and wikis. And, most importantly for us, thousands of themes have been developed to give WordPress nearly any look imaginable.



Matt has since formed Automattic—WordPress's parent company—and has been named one of the 50 most important people on the Web3 by PC World.

WordPress is currently supported by roughly a dozen core developers, and a plethora of active contributors in the community, including the creator of b2, Michel Valdrighi.

Why WordPress?

Despite all that horn blowing, why choose WordPress over the array of other excellent blogging platforms and CMSes available around the Web, including Movable Type and Blogger? Surely they have an equal number of impressive stats to spout, right? Well, you might choose WordPress for a variety of reasons:

■ It's free. Whether you're building a simple personal blog, or a high-level business website for a Fortune 500 company, working with WordPress will cost you nothing.

■ The original b2 framework was licensed under the GPL (General Public License), and so is WordPress. The GPL allows developers the freedom to modify and redistribute the software, as long as you provide others the same freedoms. This brings several advantages, including WordPress being actively developed by its community as well as the core WordPress team.

It's known for its incredibly simple 5-Minute Install.4

■ There is an enormous number of WordPress resources available on the Web, including free themes and a large number of both written and video tutorials.

■ The WordPress documentation—called the Codex5—is second to none.

■ WordPress has been around for seven years, so we can rest assured that it's here to stay, and will continue to be actively developed for years to come.

■ The WordPress team organizes community meetups, as well as conferences called WordCamps. The meetups are more casual in nature, and generally consist of team and community members talking about everything from new features in the latest version of WordPress, to tips and tricks. WordCamps consist of lectures from both core developers and community members. To learn more, visit

As with any technology choice, the decision to use WordPress ultimately comes down to personal preference. But with all those reasons, and a platform that's continually growing in popularity, it's really more a question of, "Why wouldn't you use WordPress?"



5 http://



5 http:// and

If you're entirely new to WordPress, the difference between and and might be a bit confusing at first. The first site,, is the home of the free and open source WordPress software platform. If your intention is to develop custom themes and host the CMS on your own server, is the only option., meanwhile, is a commercial entity operated by Automattic, which provides hosted blogging using the WordPress platform. It's free to use, though there are a number of premium features available for a fee.

Here are the pros and cons of each: pros

■ access to thousands of custom themes

■ use of custom widgets and plugins

■ retention of 100% control over the markup

■ access to the MySQL database, should you need to make revisions or create new tables cons

■ responsible for acquiring your own hosting, at a cost

■ manual installation of software required

■ download required of necessary plugins to prevent spam (typically Automattic's popular Akismet plugin) pros

■ hosted and managed by Automattic for free

■ hosted on hundreds of servers, resulting in virtually 99% uptime

■ set up, comment spam, and database back ups performed automatically for free cons

■ limited access to themes (around 100), and custom themes not permitted

■ unable to modify underlying PHP code

■ custom plugins can't be implemented

■ initial listing as a subdomain of, such as, though it's possible to map your own domain address to this URL

For the purposes of this book, you'll need to use the software downloaded from, and installed either on your desktop computer, web server, or virtual machine. Head over to and download the latest version6 (3.0 at the time of writing), then install it according to the instructions on the Codex.7

What is a Theme?

Don't confuse the content—the pages and posts—with the theme; they're unrelated. In fact, this separation is what makes WordPress and theming so powerful!

WordPress is a framework that provides all of the functionality for RSS, commenting, searching, querying the database, displaying posts, creating pages, and the like. The theme, on the other hand, is the skin: how it looks, the layout of the design, the CSS, added functionality, and images. Because each theme hooks into WordPress's core functions and filters in the same way, you can switch between themes with a click of a button. Any WordPress-powered site can instantly don your theme and rock a whole new look.

Each theme resides within a subdirectory of your WordPress installation called themes. If some new theme—like the one we'll start building in Chapter 5—is called "Wicked," it can be found within wp-content/themes/wicked. This separation of the presentation from the system files is incredibly helpful; it makes future updates to the WordPress framework easy, since you can update the core WordPress files without changing the theme.

Themes are essentially divided into three components:


A file called style.css contains all the style rules that will be applied to your theme. Content

Template files describe what content should be output on each of WordPress's pages: lists of posts, single posts, search results, and so on.


A file called functions.php contains any additional logic your theme needs in order to, well, function. As we'll see in later chapters, this is where you'd include plugin-like functionality in your theme: new custom widgets, or a theme-specific admin panel for customizing the color scheme and layout.

This file is immediately loaded during WordPress's initialization, and can also be modified to define common functions that are used throughout your theme.

When you download and install WordPress, you're presented with the base framework, and the default theme Twenty Ten, shown in Figure 1.1.



My Wicked WordPress Site Just another WordPress site

My Wicked WordPress Site Just another WordPress site

Hello world!

Posted on May 19.2Q10 by Louis

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

Hello world!

Posted on May 19.2Q10 by Louis

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

Posted in Uncateqorized J1 Comment | Edit

Figure 1.1. The default WordPress theme, Twenty Ten

Visiting your site's theme administration page (from the Dashboard, click Appearance, then Themes), you'll see a selection of all the themes you've installed—or just the default one if you've yet to install any—and you can activate any of them by clicking the Activate link. To test out a few different themes and get a feel for how they modify the site's appearance, select the Install Themes tab and grab yourself some new ones. You'll see how completely they can change the blog's look, but you might also start to think of ways they could be improved, or of the kind of theme you'd like to build. Perfect!

Why become a WordPress theme designer?

Well, you've already purchased this book, so it goes without saying that you want to become one! However, if you're still on the fence, it might be beneficial to ask yourself: "What do I want out of WordPress?" Do you hate the idea of using another designer's theme on your site? Did you find that none of the currently available themes suit the needs of your blog or business? Those are both great reasons to learn how to build your own theme. Some others might include being able to:

■ customize existing themes

■ convert your own website designs into WordPress templates

■ sell your theme designs for profit

■ add WordPress theme design to your agency's services

■ give back to the community with unique designs

If you identify with any of these reasons, it makes perfect sense to dive head-first into WordPress theme design. Fortunately for you, the learning curve is quite reasonable.



■ September 200fi

■ December 2007

If your ultimate goal is to turn this into a business, it can be a lucrative one if you play your cards

Was this article helpful?

0 0
Top 100 Wordpress Plugins

Top 100 Wordpress Plugins

The bulk of the plugins featured are free and available from the website. However, a few commercial plugins are featured in the Plugin Showcase within this guide. The five plugins in the Plugin Showcase aren’t rated. Less information about them is offered because, in many cases, information such as the last time the plugin was updated isn’t available.

Get My Free Ebook

Post a comment