Skip to Content

Drupal Pathauto Module

The Drupal pathauto module is a great tool for giving your content names based on the content titles. For example, the title of this blog post (node) is "Drupal Pathauto Module" so once it is saved with an automatic alias, the URL alias will be "drupal-pathauto-module" which is much easier to remember than node/9.

So, to get your SEO-friendly URLs, simply:

1) download pathauto
2) untar the files and place in sites/all/modules/pathauto directory
3) enable path and pathauto modules at system/build/modules
4) configure pathauto at admin/build/path/pathauto (Drupal 6) or admin/settings/pathauto (Drupal 5)

Now whenever you create new content, you can leave the "automatic alias" box checked and it will create the URL alias for you. Or, if you want to create your own custom alias, un-check the box and type in your alias. NOTE: AS OF CURRENT WRITING, EVERY TIME YOU EDIT THE CONTENT/NODE LATER, YOU WILL NEED TO UN-CHECK THIS BOX, WHICH IS AN ANNOYING BUG.

If you have old content that needs aliases, you can edit the pathauto settings for the particular content type. For example, I have some old blog posts that I created before adding pathauto, so I can:

1) go to admin/build/path/pathauto
2) open the Blog path settings section
3) click "Bulk generate aliases for blogs that are not aliased" checkbox
4) click save configuration

Then, all old content should have new aliases.

Important note: if you are going to be using aliases with either the path or pathauto module, make sure to prevent your site from having duplicate content.

ALL COMMENTS ARE MODERATED AND SPAM WILL BE DELETED SO SAVE YOUR TIME AND MINE AND ONLY LEAVE A COMMENT IF YOU ARE REALLY LEAVING A COMMENT AND NOT TRYING TO LINK OFF TO ANOTHER SITE FOR SOME GOOGLE LOVE.

Comments

Post new comment - ALL COMMENTS ARE MODERATED - SPAM WILL BE DELETED!

The content of this field is kept private and will not be shown publicly.
CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Powered by Drupal, an open source content management system