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.
Not compatible with autoassignrole: role by path URLs.
Not compatible with autoassignrole: role by path URLs.
Comments
Comment #1
Matt V. CreditAttribution: Matt V. commenteddoublejosh,
Can you elaborate a little bit? What do you mean when you say it's "not compatible" with autoassignrole? I'm not familiar with that module.
Comment #2
doublejosh CreditAttribution: doublejosh commentedOh I'm sorry, I keep needing it so just assumed is was widespread :)
Auto Assign Role allows creating custom registration URLs to auto assigning roles during registration. Super useful.
Your module checks for user/register but this module makes more.
Perhaps it's not possible to allow for this without directly writing code to looking for the other module.
However you could hook onto outputing the registration form rather than assuming the URL for it?
(sorry if I've made more assumptions without reading the .module)
-josh
Comment #3
Matt V. CreditAttribution: Matt V. commenteddoublejosh,
I just tested the Auto Assign Role module and it will work with Already In, but each path for assigning roles has to start with user/register. For example, if the path to assign your "king" role were "user/register/king" then authenticated users who try to visit "user/register/king" will get redirected by the Already In module.
Comment #4
doublejosh CreditAttribution: doublejosh commentedOh smart.
Guess that's a work around; though it "should" probably check for the form however it show up, no one really minds some URL restrictions.
PS: There is an Auto Assign Role Block module that probably really don't work with this.
Comment #6
ju.ri CreditAttribution: ju.ri commentedI just tested this with Auto Assign Role 6.x-2.0-beta1 and 6.x-1.2 and the redirection doesn't work on the subpaths /user/register/myrole. Only user/register does redirect.
Comment #7
Matt V. CreditAttribution: Matt V. commentedI tested both Auto Assign Role 6.x-2.0-beta1 and 6.x-1.2 with Already In version 6.x-1.0. It appears that Already In's redirect happens for Admin users who visit the user/register/ URL, but not other users.
At least in version 6.x-2.0-beta1 of Auto Assign Role, when as an authenticated non-admin user I tried to visit the user/register/ URL I had designated to automatically assign a role, I was actually logged out.
Ultimately, the Already In module exists to address the "Access Denied" issue with Drupal 6 core. With Drupal 7, Already In has been obsoleted (see #17664: user/register should show custom message instead of 403 for logged-in users).
Since Auto Assign Role will live on beyond Drupal 6, the issue of redirecting authenticated users who visit its registration URLs would better be handled in that module. Therefore, I'm re-assigning the ticket to Auto Assign Role instead.
Comment #8
doublejosh CreditAttribution: doublejosh commentedSolid thinking.
Additionally, is it possible to alter the post description since it doesn't makes much sense while in this queue.
Believe there was a title change already.
Thanks for giving this the right home.