Download & Extend

Option to just use the node ID?

Project:Short URL
Version:6.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

To reduce the need for having tonnes of extra records to manage, how about allowing nodes to be handled by just the nid, e.g. /123 would redirect to /node/123 (and, using global_redirect, from there to the full friendly URL)? It could then also be given a speed boost by including an optional patch for the site's .htaccess file to do the redirection.

Comments

#1

I was looking for similar behaviour, but I ended up implementing it using only the pathauto module:

  1. Install Pathauto.
  2. Navigate to /admin/build/path/pathauto (Administer > Site building > URL aliases > Automated alias settings).
  3. Open the "Node path settings" fieldset.
  4. In the entry for "Default path pattern", enter: [nid].
  5. Navigate to /admin/content/node (Administer > Content management > Content).
  6. Select all nodes, choose "Update path alias" from the drop-down, and click "Update".

With this, http://example.com/345 is the same as http://example.com/node/345. If that suits your need, you could probably close this feature request.

#2

What if you use already Pathauto for its most common porpouse: create friendly urls?

An alternative to consider is create .htaccess rules ?
gregg, Pathauto author suggest it in this great article
http://growingventuresolutions.com/blog/build-your-own-tinyurl-drupal-an...

nobody click here