Drupal: .htaccess Access Deny
August 21, 2014 – 7:59 am | No Comment

In this article I will tell how to forbid access to certain resources for some clients. The instructions will include descriptions of different directives.

Read the full story »
CSS Templates

Contain reviews and news about CSS Templates.

Freebies

Contain freebies such as icons, graphics, headers and images for your websites.

Fun Stuff

Contains other fun stuff for entertainment or interesting site showcase.

How-To

Contain technical elaborations on some specific workarounds or common tweak.

Joomla Templates

Contains reviews and news about Joomla templates.

Home » Fun Stuff

Quick Drupal SEO

Submitted by on February 5, 2010 – 9:26 amNo Comment

This article is devoted to quick search engine optimization of Drupal sites. Drupal is the most search engine friendly, out of the box, solution today. Nevertheless you should get some thing done to any installation.

Note: Keep in mind many of the tactics listed below are things that should be done from the get go. If you plan on implementing these tactics with a site that is already fully built, indexed and aged, then you are going to want to take different steps to ensure SERP disaster doesn’t ensue.

  • First thing is first, turn on clean URLs (which is the same thing as entering /%postname%/ in the permalink structure section in WordPress) Navigate to Home > Administration > Site Configuration > Clean URL’s. You need to make sure your server accepts mod_rewrite or this is not going to work.
  • Go download the Drupal page title module. It is going to take some tinkering to get this to work, but in the end gives you the flexibility of having different page titles than your headings.
  • To make this work you need to make sure your theme has a template.php If it doesn’t then you will need to create one (the page title module has an example one you can use). These lines need to be added to the ‘page’ hook of the _phptemplate_variables function.
  • if (module_exists(‘page_title’)) {
    $vars[‘head_title’] = page_title_page_get_title();
    }
  • Next, go download the global redirect module. This will take care of the duplicate content issues that arise from having a directory and a page with the same exact content. Eg., www.example.com/duplicate & www.example.com/duplicate/ This module will automatically redirect the “/” version of the page to the non “/” version, thus creating one version. You can also do this on your own by modifying your .htaccess file, but this is an easier solution.
  • You will also want to alleviate any canonicalization issues that your site might see from backlinks that point to non www versions or www versions. Use the following code in your .htaccess file to ensure this is taken care of.
  • RewriteCond %{HTTP_HOST} ^site\.com$ [NC]
    RewriteRule ^(.*)$ http://www.site.com/$1 [R=301,L]
  • Drupal also creates duplicate content, similar to the directory issue noted above, in the /node/ section of your site. This is a very simple fix as well. Go into your robots.txt folder and block this section of your site with the following code:
  • Disallow: /node$
  • Make sure you also download the Drupal Meta Tag module, this allows you to insert meta tags and description tags for each page/article you post on the site.

Leave a comment!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.