Thord Daniel Hedengren - Smashing WordPress_ Beyond the Blog-Wiley (2014)

(avery) #1

168 PART II • Designing and Developing WordPress Themes


◾ Generate a site map: One of the most heralded solutions for this is the Google XML
Sitemaps Generator plugin, available at http://wordpress.org/plugins/
google-sitemap-generator.
◾ The title tag: Your title tag should include both the post name (first) and the site name
(last). A divider between the two helps differentiate.
◾ Headings: On the front page, your blog’s name should be in an h1 block. When viewing
single posts or Pages, the title of the post or Page should be in the h1 block. On archive
listings (search, categories, tags, and so on), I tend to set the listing title as h1 and have
the post titles returned as h2.
◾ Reconsider links: Links are only good when they are relevant, so pushing that massive
blogroll in the sidebar all the time may not be good. This is a bit fuzzy, however, so
consider it wisely. Relevant links are always good.
◾ Related posts are relevant links: There are numerous related post plugins out there, and as
long as they return relevant links to your posts, they are a good thing.
◾ Breadcrumbs: Breadcrumbs are links, usually on the top of the page, showing where the
page is located — for example, Home ➪ Reviews ➪ Smashing WordPress. They are not
only helpful for the user, but they also help the search engine read your page. This can be
achieved within the theme or through a plugin should your theme of choice not support
breadcrumbs.
◾ Load time: It is not only users that appreciate a fast-loading site, but also search engines,
so clean up your code. You may even want to consider a caching plugin, although some
of these may end up creating duplicate content — so be sure that you read up on it
accordingly.

Also, be sure to check out the WordPress.org plugin repository’s featured and popular sections
for good SEO plugins that can make your WordPress site even more attractive to search
engines. Naturally, you’ll want your theme to be as search-engine-friendly as possible because
a lot of traffic comes that way.

It might be tempting to add a bunch of SEO plugins and start writing for search
engines, but remember this: The time you invest in tweaking your SEO could be used
elsewhere, and in the end, you should focus on content and results, rather than try to
play the system. A balanced strategy in terms of custom titles, keywords, and
whatnot versus producing new/better content is usually the best way to go.

TRIMMING WORDPRESS ON THE THEME SIDE


All sites should be as fast-loading as possible. You can do quite a lot on the theme side of
things, but the question is how much you really want to do. If you take it to the extremes,
you’ll end up with one-line files that will be completely impossible to edit, which means that
you’ll need a nonoptimized work file that you later optimize. This usually applies to style
sheets, which can be smashed together quite a lot, and hence you’ll save a few bytes, but it also
means that you won’t be able to scan them easily when looking for something.
Free download pdf