Hi,
I think I found an issue when using Pathauto and Redirect modules.
I configured Pathauto that way : when I edit a node title, the node Pathauto alias is changed and the old alias is deleted.
Redirect module catches the old Pathauto alias and generates a redirect.
Example :
with node/6, old alias is "level2-1" and new pathauto alias is "level2-2".
When I create a new node (example node/9) with title "level2-1", Pathauto creates the alias "level2-1" automatically.
But, the redirect "level2-1" to node/6 still exist.
And, when I go to URL "level2-1", I got node/9 and not node/6 like it should be (the redirect "level2-1" to node/6 is still present).
Did somebody already met this issue ?
There may be two possible solutions :
* Either the redirect "level2-1" to node/6 should be deleted
* Either the new pathauto alias takes into account the existing redirect alias ("level2-1") and generates a derivated alias ("level2-1-0").
Thanks for any idea or solution.
Comment | File | Size | Author |
---|---|---|---|
#4 | pathauto-conflist_with_existing_redirect-1287238-4.patch | 875 bytes | SGhosh |
Comments
Comment #1
nmc CreditAttribution: nmc commentedI've run into this issue as well. Looks like we may need hooks one module or the other so that they can talk to each other when necessary as not everyone may have them both installed.
Comment #2
Brian1234 CreditAttribution: Brian1234 commentedThis hasn't hit me but looks like it has the potential to (and be a bit tricky to realize what's happening).
Just a bump... it'd be nice for this to get resolved (or if it has been, close this issue).
Thanks!
Comment #3
nagba CreditAttribution: nagba commentedthere's a proposed fix on redirect module's side, http://drupal.org/node/1288768#comment-6796086
Comment #4
SGhosh CreditAttribution: SGhosh commentedI created this patch for pathauto to remove all redirects(if module exists), after saving new alias.
Comment #6
Pere OrgaTo me, the best Pathauto could do here is to not create an alias if a redirect already exists, warning the user and logging the event.
The root issue is that it's possible to have both and alias and a redirect for the same path, and I can't see a case where this would make sense.
Comment #7
Pere OrgaAnother option is to create the alias as
aliasname-0
, like Pathauto would do if an alias already exists.Comment #8
serundeputy CreditAttribution: serundeputy commentedI think this is a duplicate of https://www.drupal.org/node/2170259;
the patch there uses the non-destructive solt'n suggested by @Pere Orga
Needs to be tested by the community.
Comment #9
batigol CreditAttribution: batigol commentedOhhh redirect, global redirect, pathauto, i18n, xml sitemap, it's a loooot of testing and you often don't know witch module cause the problem...
Comment #10
jyraya CreditAttribution: jyraya at European Commission and European Union Institutions, Agencies and Bodies commentedHello,
I agree with the comments of @Pere Orga ... and I would add that this issue should be treated also in the "Path" core module because such a case can happen with "manual" aliases too.