I am using taxonaomy for some nodes and other nodes are not using any taxonomy. For the default node path pattern I am using [termpath-raw]/[title-raw].html

My problem is since some nodes are not associated with a taxonomy term they then genorate the following url in pathauto:
"[termpath-raw]/page-titleexample.html"

How do I prevent the raw token from being used in the autogenerated path for nodes that do not have taxonomy terms? Is there a work around or am I using the wrong workflow?

Thank you for any help.

CommentFileSizeAuthor
#2 820848-pathauto-termpath-empty.patch1.58 KBdave reid

Comments

greggles’s picture

Category: support » bug

I think this is a bug. The code that creates that token should default to making the token an empty string so it gets replaced (and removed) in the substitution.

The result would be a URL instead of "[termpath-raw]/page-titleexample.html" more like "/page-titleexample.html"

Is that what you desire?

dave reid’s picture

Version: 6.x-1.3 » 6.x-2.x-dev
Status: Active » Needs review
StatusFileSize
new1.58 KB

Patch attached for review against 6.x-2.x

dave reid’s picture

Status: Needs review » Fixed

Committed to 6.x-1.x and 6.x-2.x. Does not apply to 7.x-1.x.
http://drupal.org/cvs?commit=386298
http://drupal.org/cvs?commit=386312

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.