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.
I want to know whether it is possible in Domain Access module to assign users to their respective domains. I have been looking at domain user default module lately and I can't say whether it is capable of doing this or not.
Does anyone have a clue?
Thank you.
Comment | File | Size | Author |
---|---|---|---|
#7 | domain_login_restrict.zip | 1.05 KB | drupalok |
Comments
Comment #1
agentrickardThis is a core feature. See section 4.10 of README.txt.
You need this patch, too: #443836: Users gets assigned to default domain, not current
Comment #2
drecute CreditAttribution: drecute commentedThanks.
what I mean is this. If a user registers at sub.domainA.com, will he automatically be registered only to that domain? My reason for this is that I registered a user on sub.domainA.com and I was able to use the login details to register at domainA.com, which is a little bit absurd to me.
I was thinking the user at sub.domainA.com should only be able to login at sub.domainA.com and if a module like singlesignon is installed, he can be allowed to carry his session to domainA.com or sub2.domainA.com.
Comment #3
agentrickardThat is not what most people want, and not why the module was designed.
If that is the behavior you want, then do not set $cookie_domain. Then Drupal should set a different login cookie (and session) for each domain, and you can use Single Sign On if you wish.
Comment #4
drupalok CreditAttribution: drupalok commentedi need this functionality too, and i dont think cookie_domain will help. A user would still be able to login to the second domain even if he is only registered at the first one. am i wrong?
is there any module that can achieve this? and if not, where would i have to start to program it myself?
thanks in advance!
Comment #5
agentrickardIt says very clearly that Domain Access "allows you to share content and users across a network of sites."
In these other cases, you have two options:
1) Use normal Drupal multisite, not Domain Access.
2) Use Domain Prefix to prefix the {users} and {users_roles} tables for each site (use the Copy option to move only user 0 and user 1 before you create new accounts). But if you run MySQL in strict mode, you will run into this bug --> #445386: Copying "users" table fails
In the case of Domain Prefix, user registrations and logins will then be checked against the database table used by the current domain.
Comment #6
drupalok CreditAttribution: drupalok commentedthanks for the info.
domain access is really a great module and much better than a normal multisite!
we are working on a module to provide this functionality...
prefixing user table was not an option, as some users are assigned to multiple domains
greeting and thanks...
Comment #7
drupalok CreditAttribution: drupalok commentedwe created a module so users can only login to a domain they are assigned to.
works for us, check it out
Comment #8
drecute CreditAttribution: drecute commentedComment #9
agentrickardAs far as the main module goes, this is 'by design' and will not be changed.
#7 should be released as a stand-alone module.
Comment #10
drecute CreditAttribution: drecute commentedhi drupalok,
nice module. i guess u guys beat us to it. Cos myself and a friend were working on one as well. My question is does your module automatically assign users to a domain on creation or using domain access it just register that user to the current domain at which it was created.
Thanks.
Comment #11
drecute CreditAttribution: drecute commentedComment #12
drupalok CreditAttribution: drupalok commented@agentrickard
i am under the impression you are kind of annoyed by my postings... i am sorry if i did something wrong. i did not want to argue with you in any way. your module is just great!
@drecute
the module does not change the registering of domain access
unfortunately at the moment all users from all domains get registered to the main domain
see:
http://drupal.org/node/443836
it says the patch has been commited but i dont think there is a release yet
Comment #13
agentrickardWell, I'm just trying to unclutter my queue to get the stable release out. (see #12). Issues like this slow that down.
See #443296: Tasks for stable release
Retitling for clarity.
Comment #14
drecute CreditAttribution: drecute commentedFrom your response, that means login details from non-main domain can used to logon to the primary domain. But for example, user at sub.primarydomain.com cannot log on to sub2.primarydomain.com and vice-versa.
This is just the way I understand it.
Comment #15
agentrickardThis has been released over at http://drupal.org/project/domain_bonus