I think a field to enter in an alternative below the default would be nice, and a corresponding option to pick an alternative separator, in the 'punctuation' settings.

For example, Google Sites uses a dash as the normal separator, as most sites do by default, but if you enter a colon as the title for your post, it gives you a double dash, as in --.

This way i could set it to the alternative for say, colons, so my post title for "Topic: Ritual Killings" would get aliases like:

I've tested these patches on my sites, running the current versions of pathauto 5.x-2.3 and 6.x-1.1
Let me know what you think.
First patch is for 6.x-1.1

Members fund testing for the Drupal project. Drupal Association Learn more


aterchin’s picture

This patch is for 5.x-2.3

greggles’s picture

Status: Needs review » Postponed

Thanks very much for your work on this. I'd love to enable developers to build creative things like this, but the UI is currently really overwhelming with options and we need to slim it down.

So, I'm not sure whether to mark this postponed or won't fix.

This adds complexity to the UI. We really can't do that. So, it's won't fix.

As you know (#212208: allow other modules to affect strings (to help with custom accent/string replacement)) there are ideas/code to move this whole punctuation stuff to a separate sub-module or something like that. So, this could be postponed until then.

I guess postponed is a bit more positive ;) If you are interested and willing to help, please consider working to make a sub-module for Pathauto that does all this crazy string stuff and which has hooks to enable other custom modules to do similar things.

aterchin’s picture

That makes sense. Until then, or when I get the time to figure out how to incorporate some of this stuff into a submodule, I'd encourage anyone who tries this patch out to report back on how it's working for them.
Thanks Greg.

Dave Reid’s picture

Version: 6.x-1.1 » 7.x-1.x-dev

Feature requests are bumped to 7.x-1.x/6.x-2.x now. 6.x-1.x is feature frozen.

cindyr’s picture

Has anyone gotten this to work on 6.x-2.x?

Dave Reid’s picture

Status: Postponed » Closed (won't fix)

After reviewing this again, I don't think this is a good idea to put into pathauto. We should provide extensibility and APIs to allow things like this, but let's keep it simple.

Francewhoa’s picture

Issue summary: View changes
Status: Closed (won't fix) » Needs review
72.62 KB

Same here. We need to output URL as follow: story/lorem--ipsum-dolor
Notice the two dashes --

Another examplestory/lorem---ipsum---dolor
Notice the three dashes ---

We extensively use those double and triple dashes. Mostly because it make the URL easier to read for users.

Currently pathauto is not able to do the above. Anyone know any options to do output alternative double or triple dashes into a URL using pathauto? We searched but found no alternative, no other modules either.

How about this mockup below? It shows the suggested new feature and its workflow.
Mockup add separator

If the pathauto module maintainers choose to not add that feature that's really okidoki. Then how about adding a sub-module? Which would be deactivated by default. So no change to pathauto default feature. Users interested in that alternative separator feature could simply enable that sub-modules. Any other suggestion?

Any volunteer for a patch or an updated patch? The Ubertus team would be happy to contribute patches testing and documentation.