Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

PortalWebHosting
  Ads  
Active Modules -- Active Forums for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

SteadyRain
DataSprings - Great Ideas. Always Flowing.
R2integrated - formerly bi4ce
Jango Studios - Skins, Modules and Hosting for DotNetNuke
eUKhost.com is commited to offer exceptional UK Windows Web Hosting solutions with quality 24x7 technical support.Our plans support ASP.Net, ASP, ASP.NET Ajax extensions, XML, MSSQL, MySQL, PHP,DNN, multiple domains and Shared SSL as standard.
SmarterTools
 


DotNetNuke Forums
 
  Forum  General DotNetN...  Configure It! (...  multi portal sharing users
Previous Previous
 
Next Next
New Post 6/13/2007 9:52 PM
User is offline Fuji Nguyen
195 posts
9th Ranked




Re: multi portal sharing users 

 penra wrote

What syntax would you use? Can you show a specific example of adding a user (can you add groups?) to another portal?

thank you mcsenow!

The solution is database trigger in the event of insert or update to DNN User table.  When you add a new user or update an existing user, the trigger will automatically run to setup the user as share user to all portals (parent and childs). 

Example 1 - if you have a parent portal and 5 child portals.  You add a new user "penra" to the parent (or any child) portal, the same account (penra, pw) can be used to login other portals (ex. the 5 child portals).  

Example 2 - if you have an existing user "penra2" in the parent (or amy child) portal and you use the Admin -> User Manager to update the account, the trigger will set up penra2 account to share among all portals.

Keep in mind that the existing accounts that were setup in DNN before the trigger was added will not be setup as share accounts among the portals UNLESS the accounts are updated (by admin via User Manager screen or by individual via profile screen).  This is because the trigger will not run unless there is insert or update event to table DNN user.

Hope this helps.


Fuji Nguyen
FREE Visitor Hit Counter
Visit opensource.indyneinc.com for detail.
 
New Post 1/13/2008 2:50 PM
User is offline Pete
24 posts
10th Ranked


Re: multi portal sharing users 

Fuji Nguyen,

Your SQL solution is superb... I have one issue with it that I hope someone can help me with.

This creates the same user against every portal in the installation, but it does not add any security roles to the user for portals other than the one they registered on. Thus if you have a page that is only visible to registered users they will not be able to see it unless you admin their account and add the user to the registered user role.

What I would like is to add the user to all the portalID's which it already does and then add all the roles that are set to auto-assign when they add to a portal (default being "registered users" & "subscribers"... That way if they come back and unsubscribe, even if they update their account... it will not subscrive them again because it will be using the same logic that says "This user already exixts for this portal therefore do not add them".

I'm hoping someone is feeling charitable... because sadly my SQL abilities rank up there with my cooking skills... Please help!

Kind regards

Pete


Aarrgghhh! User Error DNN Version: 4.4/4.5
Websites: taxinumber.com/taxi-today.com
Like DNN? Yes! Very much, congratulations!
Poor eyesight? Yes! Thankyou very much!
 
New Post 1/19/2008 1:57 PM
User is offline Pete
24 posts
10th Ranked


Re: multi portal sharing users 

Anyone feeling charitable?


Aarrgghhh! User Error DNN Version: 4.4/4.5
Websites: taxinumber.com/taxi-today.com
Like DNN? Yes! Very much, congratulations!
Poor eyesight? Yes! Thankyou very much!
 
New Post 3/18/2008 1:11 PM
User is offline Fuji Nguyen
195 posts
9th Ranked




Re: multi portal sharing users 

Pete,

Follow the example trigger I posted and see if you can come up with the ones you need.  Give it a try and if you need help, post in this forum.

Background:  DNN security roles Administrators, Registered Users, Subscribers exist in each portal.  Table 2 has example of these built-in roles for portalid 0 and portalid 2.  The objective is to create records in table UserRoles (Table 3) for each combination of RoleID (Table 2) and UserID (Table 1).   I think you will need to add triggers to table Users and Roles.

Table 1 - Sample data from table Users

UserID Username FirstName LastName
1 host SuperUser Account
2 admin Admin Istrator
3 test test test
4 ACKE02 ALLEN ACKERMANN
5 ADAM10 BRANDT ADAMS
6 ADAM08 PHILLIP ADAMS
7 NGUY01 D. FUJI NGUYEN
8 testtest testteste est
9 alan0 Alan Brewer

Table 2 -  Sample data from the Roles table
RoleID PortalID RoleName Description
0 0 Administrators Portal Administration
1 0 Registered Users Registered Users
2 0 Subscribers A public role for portal subscriptions
3 0 TimeXP TimeXP
7 2 Administrators Portal Administration
8 2 Registered Users Registered Users
9 2 Subscribers A public role for portal subscriptions

Table 3 - Sample data from the UserRoles table

UserRoleID UserID RoleID
1 2 1
2 2 2
3 2 0
5 3 1
6 3 2
7 3 3
8 4 1
9 4 2
10 5 1
11 5 2
12 6 1
13 6 2
17 2 8
18 2 9
19 2 7
20 7 1
21 7 2
22 8 1
23 8 2
24 9 1

 

Fuji.


Fuji Nguyen
FREE Visitor Hit Counter
Visit opensource.indyneinc.com for detail.
 
New Post 4/9/2008 4:55 PM
User is offline Kmideas
65 posts
10th Ranked


Re: multi portal sharing users 

Thank you fuji.. this is very helpful.

Along the same lines...

I've been trying to add a user and the user's role to one portal when it is created in another. The portals would be separate instances of DNN, not Parent/Child.  Is that possible? 

Thank you for your help. 

 
Previous Previous
 
Next Next
  Forum  General DotNetN...  Configure It! (...  multi portal sharing users
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:

1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


ExactTarget Email Marketing Software and Solutions
ExactTarget delivers on-demand email software solutions for permission-based email marketing. ExactTarget offers solutions that meet the needs of all industry verticals and all size organizations, including SMB, corporate divisions, not-for-profits, large retail/direct marketers, agencies and enterprises.
ExactTarget.com
Sunset Hill Solutions - Consulting and Development
We offer general DNN consulting services - including custom module development and commercial module integration/setup.
www.sunsethill.ca
MaximumASP
MaximumASP provides a wide array of web hosting plans to fit any hosting need. We also provide software and services needed to keep it running optimally.
MaximumASP.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP