From: Dr. D. R. N. <d.r...@qu...> - 2004-07-07 22:34:53
|
I needed, for several Tikiwiki sites, to collect extra information when people register. On www.tikiwiki.org we want to be able to contact people who register in particular constituencies, and invite them to local meetings. On sites set up for my students, I want to know which modules they are studying. None of this is found in the standard user registration data. The solution I implemented is to link registration to a tracker. 1. From the login admin page I can select a tracker. 2. From the tracker field admin page I can select particular fields to be presented on the registration form. 3. Then when someone goes to register, they see the standard registration fields, followed by the selected fields from the selected tracker. 4. When the registration is accepted, the values they completed for the extra fields is stored in the tracker. (If your tracker includes fields called 'name' or 'email', the chosen username or e-mail address is stored in the tracker as well as the users table.) I also added the ability to set passcodes per group. So you can send out a promotion inviting people to enter a special passcode on registration. When they use the passcode, they are immediately made a member of that group. I made the modifications on tikiwiki 1.8.3 (as I'm going to put them into use on a production system). I've zipped up all the changed files, and uploaded them to the Patches section on Sourceforge. There are also some database changes needed: # adding field for group passcode feature ALTER TABLE `users_groups` ADD `groupPass` VARCHAR( 64 ); # adding data for linking registration to a tracker ALTER TABLE `tiki_tracker_fields` ADD `isRegister` CHAR(1); INSERT INTO `tiki_preferences` (name, value) VALUES ('registerTrackerId', '0'); |