Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
There is currently an issue when a user is making AJAX requests and then is autologged out.
Use case:
- User votes on a post using AJAX. (Note: The AJAX request URL is something like /vote/node/NID/1/voteupdown/f351f5ace551efdb74d4954e81889466)
- User is away and is autologged out.
- Autologout logs the user out to a URL like: /logout?destination=vote%2Fnode%2FNID%2F1%2Fvoteupdown%2Ff351f5ace551efdb74d4954e81889466&autologout_timeout=1
- When the user logs back in, they are redirected to the voting URL rather than the page that they were on when they made the AJAX request.
After making an AJAX request, the redirect URL should continue to be the URL of the page that they were on when they made the AJAX request, since they never really left the page.
Comment | File | Size | Author |
---|---|---|---|
#5 | autologout-autologout-ajax-redirect-url-2129297-4.patch | 753 bytes | mecmartini |
#1 | autologout-redirect-url-2129297.patch | 915 bytes | mark.lindsey |
Comments
Comment #1
mark.lindsey CreditAttribution: mark.lindsey commentedComment #2
johnennew CreditAttribution: johnennew commentedHi Mark,
Thanks for your patch. It looks good and I've gone ahead and added to the 6.x-4.x branch.
Setting to 7.x-4.x to port to latest version
Comment #3
mecmartini CreditAttribution: mecmartini commentedHi,
I made a patch for 7.x-4.3. Thank you it's very usefull!
Comment #4
johnennew CreditAttribution: johnennew commentedBrilliant - thanks very much - I have pushed this to the 7.x-4.x development branch.
Comment #5
mecmartini CreditAttribution: mecmartini commentedSorry ceng I did an error in the patch. Here is the correct one.
Comment #6
johnennew CreditAttribution: johnennew commentedAh, good spot.