Author |
Topic |
|
ftropea
Starting Member
16 Posts |
Posted - 08 September 2003 : 19:46:50
|
This might be useful for someone so I decided to post it up here.
The following MOD allows you to selectively restrict registration based on the Email addy used. For example, let's say you want to hold off the registration of only those members coming in with a "Yahoo" or "Hotmail" email addy. These members would be tagged as "needing approval" and will appear on your members pending list. Until you approve them, they don't get the confirmation email with the link for completing registration. All other members coming in with email addys you don't restrict can register normally.
This is helpful if you find that a lot of your troublemakers or "hit and run" type posters are registering under Hotmail or Yahoo type accounts. This MOD won't prevent them from registering, but the process won't be complete until you manually approve them for the next step which is email validation :-)
I suggest you also install the MOD where it let's you view the profile of pending members. This way you can peak at the member info and decide whether or not you want to approve.
MOD INSTRUCTIONS (EASY: Only 2 Changes to Register.asp!):
1. Under your ADMIN SECTION screen, go to E-mail Server Configuration and check to see if you've got everything configured to allow Email funtionality. This should already be done if you've been using Email Validation to approve members.
Also, make sure "E-mail Validation" and "Restrict Registration" is set to ON. (Don't worry - this MOD will not force you to approve EVERY member.. only the ones with Email addys you're trying to "filter"!)
2. Backup a copy of your REGISTER.ASP file. This is the only file we'll need to modify.
3. At around line 47 of REGISTER.ASP, find these lines:
%> <!--#INCLUDE FILE="config.asp"--> <!--#INCLUDE FILE="inc_sha256.asp"--> <!--#INCLUDE FILE="inc_header.asp" --> <!--#INCLUDE FILE="inc_func_member.asp" --> <!--#INCLUDE FILE="inc_func_posting.asp"--> <!--#include file="inc_profile.asp"--> <%
..and add this BELOW that code:
'###### Selective Email Registration Restriction MOD #####
strRestrictReg = "0"
'###### End of Mod #####
4. At around line 460, find these lines:
'################## E-mail Validation Mod ######################## if strEmail = "1" and strEmailVal = "1" then strSql = strSql & ", " & "'" & chkString(actkey,"") & "'" strSql = strSql & ", " & "-1"
...and add this BELOW that code:
'###### Selective Email Registration Restriction MOD #####
dim check_email
check_email = Trim(chkString(Request.Form("Email"),"SQLString"))
If Instr(2, check_email, "@aol") then strRestrictReg = "1" If Instr(2, check_email, "@yahoo") then strRestrictReg = "1" If Instr(2, check_email, "@hotmail") then strRestrictReg = "1"
'###### End of Mod #####
You can keep adding IF-THEN statements for every domain you want registration restricted for.
That's it! So now when someone registers with an Email addy from one of those restricted domains, you'll see them as 'Needing Approval' in your "MEMBERS PENDING" list in your Admin section. Until you approve them, they won't receive a confirmation email and be able to complete registration.
Hope this is helpful! :-) |
Regards,
Frank A. Tropea www.SegwayChat.com |
Edited by - ftropea on 08 September 2003 21:59:57 |
|
jeffery
Junior Member
USA
176 Posts |
Posted - 08 September 2003 : 21:44:19
|
Great mod!
quote: I suggest you also install the MOD where it let's you view the profile of pending members. This way you can peak at the member info and decide whether or not you want to approve.
Any idea where this mod is? I cant seem to find it. I know I've seen it. |
www.thomasforum.com |
Edited by - jeffery on 08 September 2003 21:44:35 |
|
|
ftropea
Starting Member
16 Posts |
|
jeffery
Junior Member
USA
176 Posts |
|
Classicmotorcycling
Development Team Leader
Australia
2084 Posts |
Posted - 09 September 2003 : 22:48:39
|
Just what I have been looking for.. Good stuff, will test it out tonight (Australian time)...
|
Cheers, David Greening |
|
|
gelliott
Junior Member
USA
268 Posts |
Posted - 10 September 2003 : 12:16:45
|
I've been out for a while (crazy at work) - I've copied my Pending Members Profile Mod out to SnitzBitz as well, for posterity... |
* The optimist says the cup is half full. The pessimist says it's half empty. But the engineer knows the truth - the cup's design is incorrectly sized. |
|
|
|
Topic |
|