Sign In  |  Register
 
 DotNetNuke Powered!
DotNetNuke Support Forums

How do I import users from a text file?

Rate this topic:

Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

AuthorMessages
sharindenver
Posts:54



07/10/2007 8:41 AM  

I would like to create a list of users in a text file and import it.  Setting all new users to have the same password and set the flag to force them to update their password on first login.  The file would need to have: username, first name, last name, password, email, update pw flag.  I think that's it.  They can all just be Registered users.  Then I can go in and set their security accordingly. Is there a module that does this?  or a way to just do it through the db?

John Mitchell
Posts:3369



07/10/2007 9:28 AM  

Hi Sharlyn,

I have a script to import users into DNN here:

Importing Users to DotNetNuke

sharindenver
Posts:54



07/10/2007 10:54 AM  

So can I define the fields I want to use and change the script and xml accordingly?  Just make sure what the field is in the table?

John Mitchell
Posts:3369



07/10/2007 10:56 AM  
Yes you can. There are only a few fields that are required when creating a new user.
sharindenver
Posts:54



07/10/2007 2:48 PM  

Hey John... what is the best way to get the users in an XML file if they are not currently in a db?  Can I make a txt file separated by commas and carriage return?  then pull from the txt file to create the xml format?  Or do I need to create the xml file from scratch?

sharindenver
Posts:54



07/10/2007 2:51 PM  
Also, how do I use the importusers.aspx from my dnn site? :)
John Mitchell
Posts:3369



07/10/2007 2:55 PM  
Put the ImportUsers.aspx page in the root of your site, or some other folder and then open it in the browser.

It'll present you with a textbox to paste you XML into.
greenflash
Posts:45



07/19/2007 9:05 AM  
John,

I have three portals, can i import users to specific portal from xml file?

DotNetNuke Türkçe
SnapsisHost
Posts:103



07/19/2007 9:11 AM  
Yes, you would just need to change the portalid in the code-behind (importusers.aspx.vb), and then run it seperatly for each portal.

If you get adventurous you could add the portalID to the UI page and read it in from the code-behind.
jncraig
Posts:79



05/21/2008 12:08 PM  
Another question -- I would like to modify this script so that the users are created in a "verified" status, and so that the standard email is sent with their username, password, and verification code. I figure it's a one or two line change that I don't know right off the bat.

Can you help me?
Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

Forums >DotNetNuke Support >Frequently-Asked-Questions > How do I import users from a text file?



ActiveForums 3.7
Visit our Store for great DotNetNuke Modules and Skins
DNNMasters Sitemap/Google Sitemap 3.0

Item codeSM3-01
Price$29.00
Product Information 
DotNetNuke CSS NavMenu 3.3 (Developers)

Item codeCSSNM33DEV
Base Price$149.00
Product Information 
Snapsis PageBlaster 3.3.2 for DotNetNuke - Professional Edition

AuthorJohn Mitchell
Base Price$79.00
Product Information 
XDAkuna (Web 2.0 CSS XHTML Skin)

Item codeXDAkuna
AuthorNina Meiers
Price$49.00
Product Information