Register now and start sharing your code snippets.

How to optimize your MephistoBlog powered site's search engine ranking (SEO for MephistoBlog)

Plain Text posted 17 days ago by christian

At Aktagon we use MephistoBlog as CMS , and I couldn’t find any information on how to SEO optimize MephistoBlog on Google, so I’m sharing my notes here.

This tip shows you how to make your pages more search engine friendly.

First, add the title tag, plus the meta description and keywords tags to your layout’s Liquid template , as shown here:

   1  <meta name="description" content="{% if article %} {{ article.excerpt }}  {% else %} YOUR DEFAULT SITE DESCRIPTION {% endif %}" />
   2  	<meta name="keywords" content="{% if article %} {% for tag in article.tags %}{{ tag }}, {% endfor %} {% endif %} YOUR DEFAULT KEYWORDS" />
   3  	<title>{% if article %} {{ article.title }} &raquo; {{ site.title }} {% else %} {{ site.title }} &raquo; {{ site.subtitle }} {% endif %}</title>

Remember to update the default description and keywords in the meta tags’ body.

Now, whenever you publish an article, simply add an excerpt and some tags to it. The excerpt is used as the meta description and the article’s tags as the meta keywords, both make Google a bit happier, but the description is by far the more important.

Tagged seo, mephistoblog, meta, google, search, keywords

A simple image replacement technique for increased usability and SEO ranking

CSS posted 12 months ago by christian

This is currently my favorite image replacement technique. I don’t remember where I found it… Using it can improve both your site’s usability and your search engine ranking, by allowing both screen readers and search engines to find your h1 headlines. First create the h1 and the description of your page/site, for example:

   1  <h1 id="logo">Viagra, Botox, you name it</h1>

Then create the CSS rule for the page title:

   1  h1#logo {
   2    text-indent: -9000px;
   3    background: url(logo.gif);
   4    width: 200px; /* Width of image */
   5    height: 50px; /* Height of image */
   6  }

People using a modern browser that support CSS will see your logo (the image), and search engines and people using less modern browsers will see the content of the h1 header tag.

Note that if you replace the text of a link then use the outline CSS property to remove the dotted border:

   1  .text-replacement {
   2  	text-indent: -9000px;
   3  }
   4  
   5  .text-replacement a {
   6  	outline: none;
   7  }

Tagged css, image, replacement, usability, seo

How to improve your PageRank with 301 permanent redirects when using Nginx

Plain Text posted about 1 year ago by christian

Mathew Innman of seomoz.org fame wrote about how Digg could increase their revenue by using a so called canonical URL for their whole site. This can be implemented by redirecting users that type in, for example, www.digg.com to digg.com. The reasoning being that instead of having backlinks pointing to two different domains (www and no-www), all backlinks should point to just one, which increases your search engine ranking.

   1  if ($host ~* "www") {
   2        rewrite ^(.*)$ http://aktagon.com$1 permanent;
   3        break;
   4      }

Permanent redirects are also a good idea, if you move your content to a new domain—digg.com to dugg.com, for example…

The syntax for the Nginx rewrite module is documented here.

Tagged seo, www, 301, permanent, nginx, redirect, rewrite, module

How to submit your sitemap to multiple search engines

Plain Text posted about 1 year ago by christian

To submit your sitemap to search engines—at least Google, MSN and Yahoo support this feature—add this line to your robots.txt file:

   1  Sitemap: http://aktagon.com/sitemap.xml

This allows the search engine to find your sitemap when it visits your site, which means you don’t have to manually register it with each search engine.

Tagged seo, sitemap, google, search

Check which of your pages are in the Google supplemental index a.k.a Google hell

Plain Text posted about 1 year ago by christian

Try this query to find pages that are in Google’s supplemental index (trick invented by Bruce Clay, Inc):

   1  -site:aktagon.com/* +site:aktagon.com/

The query should list all of your pages that are in Google’s supplemental index a.k.a Google hell. These pages lower your Google page rank, so you should tell Google not to bother indexing those pages. This can be done with robots.txt:

   1  User-agent:*
   2  Disallow: /tags/*
   3  Disallow: /archive/*

Another way of doing it is to add a meta tag:

   1  <meta name="robots" content="noindex,follow"/> 

This tells search engines to read the page but not index it.

And, be careful with what you put in robots.txt…

Tagged seo, google, robots.txt, noindex, follow