There’s been a lot of talk lately about ThemeForest, Envato, WordCamps, and the GPL. I’ve been paying close attention because, you know, themes. I love them. I think they’re a huge part of the WordPress mission to democratize publishing and I think the good ones are making the world a more beautiful and better place. I also think they should be free, open source software — the whole deal, CSS, images and all — just like WordPress. Try deleting all the CSS and images from your favorite theme and from WordPress. It’ll help you understand why, while technically theme authors don’t have to let you fully own those things, they really shouldn’t be taking that freedom away from you and locking them down. This is one of the core values of WordPress and fundamental to the market in which people develop and sell themes.
Anyway, other people have made this point more eloquently than me. What I really want to talk about is a change in the Envato license that no one is really talking about. That is, the recent Marketplace License Updates and how it affects WordPress theme licensing on ThemeForest.
You’ve created an amazing theme and now you want to share it with the rest of the WordPress community. In this lesson, we’ll walk through the best practices to follow when preparing your theme for distribution.
With the templates and CSS in place, let’s round off our theme building by adding a way for visitors to add a personal touch with their own Custom Backgrounds and Custom Headers.
I recommend adding support for these features after you’ve completed the CSS for your theme. It’s faster this way, because you can make the preview of the Custom Header and match your theme’s design. Plus, it’s easier to test the implementation of both backgrounds and headers when your design is complete. Think of them as the final flourish for your theme!
Please Note: The examples in this lesson are based on the design of the Shape Sample Stylesheet from the CSS lesson. If you want your header styles to look like those in the screenshots in this lesson, you’ll need to replace the styles in your current style.css with those from download.
CSS can be tricky. It can also be incredibly easy. I had a lot of help getting my head wrapped around CSS when I was first starting out and I take great pleasure in helping others the same way I was first helped: with solid code examples to learn from.
We’re going to round off our theme template building with the sidebar and footer templates.
Let’s start with sidebars. In WordPress, term “sidebar” refers to the part of a theme that contains widgets.
archive.php does (and all its related templates) is show posts based on a select criteria. A date range, or posts by a certain author, a category, or a tag. So, basically, it’s a lot like
Our theme will have one multipurpose
archive.php template to cover date, category, author, and tag archives.
The Search Template and The Page Template are vital to any complete WordPress Theme. And they’re both really easy to code.
I hate the Comments Template. There, I said it. It can be a confusing mess.
Luckily for you, I’ve sorted it out. Confusing still, yes. But sorted out. For this tutorial on the Comments Template, I’m basically going to walk you through what’s going to happen, show you some custom code snippets you’ll need to add to your
inc/template-tags.php file, and then drop the whole thing on you. Hopefully, it’ll start to make sense. But at the very least you’ll have a wicked comments template.
You’ve built an index of all your posts, now you need to create a template to frame each piece of content (or missing content) on its own. In this lesson, you’ll create templates for single posts, post attachments, and 404 error pages.
Index.php is the most crucial WordPress Theme Template. Not only because WordPress needs to use it if you’re missing any of its brother and sister templates (like,
tag.php) but because the work we do here, getting this template right, will help us breeze through the rest of our templates (with the exception of the dreaded comments template; that’s just plain difficult no matter how you look at it).