The description for the Language Path Checking setting says "If enabled, the module will check that the page being viewed matches the language in the URL or the system default. For example, viewing a French node while the site is in English will cause a redirect to the English node."
To me, this sounds like it should only redirect when viewing a node, not editing, deleting, translating etc. I've looked through the code, and afaict, it's simply a matter of changing the regular expression that checks the current path.
Is this the intended behavior? If it is, I propose changing it, or maybe provide an additional setting that allows us to ignore the redirect when we're not actually viewing it.
Comment | File | Size | Author |
---|---|---|---|
#2 | language_redirect_view_node-1399506-2.patch | 820 bytes | olofbokedal |
#1 | language_redirect_view_node-1399506-1.patch | 822 bytes | olofbokedal |
Comments
Comment #1
olofbokedal CreditAttribution: olofbokedal commentedProvided patch changes the regular expression to match node/123, node/123/view and node/123/.
Comment #2
olofbokedal CreditAttribution: olofbokedal commentedThe regex in the previous patch didn't work as I suspected, so here's a new one.
Comment #3
Schnitzel CreditAttribution: Schnitzel commentednice! Had extactly the same problem and the patch at #2 works charming!
thanks
Comment #4
Cyclodex CreditAttribution: Cyclodex commented+1 really nice. Just in time :D Thx
Comment #5
Frederic wbase CreditAttribution: Frederic wbase commentedI've just installed the dev version of this module and it seems to be working now.
Can i asume that this fix has already been commited to dev? If so, can we close this issue?
Comment #6
olofbokedal CreditAttribution: olofbokedal commentedSimply by looking at the code, I can tell that the patch from #2 hasn't been applied.
Haven't tried it out though, maybe it has been fixed in another way?
Comment #7
Carl Johan CreditAttribution: Carl Johan commentedThis issue hasn't been fixed in 7.x-1.5 and the patch still applies.
Comment #8
edux CreditAttribution: edux commentedStill the issue hasn't been fixed, I think this is a bug that needs to be reviewed, the patch in #2 did the job for me.
Comment #9
yannickooWorks fine so let us set the status to RTBC :)
Comment #10
nicholasThompsonFixed in dev - Also updated the tests to remove the 3 node edit language redirect tests.
Thanks guys.
Comment #11
yannickooFinally! <3
Comment #14
mas0h CreditAttribution: mas0h commentedWhat if the opposite is needed, I mean to redirect to the source language only when editing content, not viewing?
Thanks!
Comment #15
stefan.r CreditAttribution: stefan.r commented@mas0h: if you want to do this while editing content as well, check out Node Edit Redirect
Comment #16
stefan.r CreditAttribution: stefan.r commentedThis caused infinite redirects on the node edit form when other modules are already changing the interface language (see: admin_language).
Yet another reason to tag a new release, since the last one is from 2012 :)