I'm using Pathauto 5.x-2.x-dev and finding that there are issues with punctuation in node titles and categories when aliases are created.

With node titles, punctuation is not being stripped away. For example, if I title a node: "This: Is A Test!" then the alias will be sitename.com/category/this:-is-a-test! when I hover over the link. If I actually follow the link and view the full node, the URL then shows as sitename.com/category/this%3A-is-a-test%21, with the punctuation being replaced by other characters.

With categories(default taxonomy module), I am having similar issues with categories that have a "&" character, as they are not being stripped away. For example, if I create a node and select a category of advertising & marketing, the alias for the category shows up as sitename.com/advertising-%2526-marketing-0 instead of sitename.com/advertising-marketing like it used to when I was using 5.x-1.1. BTW, I switched over to 5.x-2.x-dev because of issues with the include file, which is referenced elsewhere in the issue queue.

Any help would be much appreciated!

Comments

greggles’s picture

Title: issues with punctuation in node titles and categories when aliases are created » document transliteration and punctuation changes for 5.x

Well, this is a "feature" of the 5.x-2 branch. So...it sounds like we'll need to do lots of documentation :)

Basically the point is that the title is the title whether it contains non ASCII-96 characters or punctuation it should be put directly into the title. You can get around this behavior by using the i18n-ascii.txt file to "transliterate" from ! to your separator character.

Can you please test that and let me know how it goes?

Also, what is the include problem you mention?

Thanks for the help in testing!

David N’s picture

Thanks Greg! I will definitely try that out as soon as I can. As for the "include" issue, my memory had it mixed up with an issue with the Token module, that involves Pathauto. It's been referenced here: http://drupal.org/node/139959

I switched over to 5.x-2.x-dev because I was having issues like the one mentioned here: http://drupal.org/node/124701. Those are gone now, thankfully.

On a sidenote, I noticed that 5.x-2.x-dev doesn't display help tips that tell a user what he/she might use to create aliases. For example, [cat] [title] [user] [vocab] etc. I take it those are still applicable though?

greggles’s picture

Title: document transliteration and punctuation changes for 5.x » document transliteration/punctuation and token/pattern changes for 5.x

Hi - the problem with the list of available tokens not showing means that you probably didn't apply the patch from http://drupal.org/node/139959#comment-237674

Anyway, that's out of scope of this issue...

Another thing that brings up is that some of the tokens have changed now as well. I changed the title to reflect that. Thanks!

David N’s picture

Greg,

Some followup: The transliteration worked like a charm. This newest version doesn't appear to be throwing me any curveballs; thank you for your hard work.

There is some unexplainable behavior though, that I cannot figure out. When I generated bulk aliases for my taxonomy, it would take for example, taxonomy/term/100 and create an alias for a node that doesn't exist and call it forum/100, even though I don't have the forum module enabled. It would assign an alias of "cars" for example, to forum/100 instead of to taxonomy/term/100, which was assigned "cars-0." Not a big deal, as I just went in and deleted all the forum/* aliases and renamed the terms with 0 at the end of them.

greggles’s picture

Good to hear.

There is a forum bug that I haven't looked at much which I need to look into...Wim Leers is working to fix it in http://drupal.org/node/118676

One other thought about the punctuation/transliteration support - can you provide a list of the punctuation marks that you've changed over? I think it could be helpful to provide those either as commented out examples or in the INSTALL.txt so that folks can see how it should work.

Thanks!

greggles’s picture

Category: bug » task
greggles’s picture

From an email - "!, :, ?" were the punctuation types that were problematic.

greggles’s picture

Well, one is [user] to [user-name]

taqwa’s picture

I'm not sure if this is the right thread for this, but my apostrophes show up as 039.

meatbites’s picture

Lukas, your issue is easily fixed by a patch I made, which is awaiting review. You can try it out here: http://drupal.org/node/167786

karunadave’s picture

There used to be tokens for events, such as [eventdd] [eventmon] [eventyyyy] [title]

Using these would give me an event node path such as 14_09_2007_Eventtitle. At the moment I am getting
http://www.lamayesheling.org/%5Beventdd%5D_%5Beventmon%5D_%5Beventyyyy%5.... Ack!

HorsePunchKid’s picture

@karunadave - Check out this issue for the event module, which contains a possible solution.

greggles’s picture

Title: document transliteration/punctuation and token/pattern changes for 5.x » document transliteration, punctuation, pattern, Bulk Generation changes for 5.x-2
Component: Miscellaneous » Documentation
Status: Active » Needs work

Well, I decided to create a wiki page on groups.drupal.org because that seems like the easiest way to collaborate on this

Please see (and hopefully provide feedback on) http://groups.drupal.org/node/6706

Thanks.

greggles’s picture

I just spent a little while refreshing that page by organizing the bullet items into "new features/reasons to ugprade" and then "upgrade advice".

Realistically, people need motivation to upgrade aside from the fact that 5.x-1.x is going to die. When I stepped back and looked at all the new features I was actually surprised at how many new features are available in this version.

greggles’s picture

Status: Needs work » Fixed

I'm going to call this good.

Thanks folks.

Anonymous’s picture

Status: Fixed » Closed (fixed)

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