Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Allow only one domain to register
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Allow only one domain to register

 Post Reply Post Reply
Author
lsabug View Drop Down
Newbie
Newbie


Joined: 02 June 2003
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote lsabug Quote  Post ReplyReply Direct Link To This Post Topic: Allow only one domain to register
    Posted: 02 June 2003 at 4:50pm
Greetings,

I'm a bit stuck as to how to limit registration from only one domain, ie. www.alloweddomain.org. All other domains (yahoo.com, rr.com, etc.) wouldn't be able to register. Is there an easy way to do this?

Much obliged.
lsa
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 02 June 2003 at 4:58pm
You need to have email notification enabled for this and set the domain as one to not allow for email addresses.
Back to Top
fernan82 View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 17 November 2002
Location: United States
Status: Offline
Points: 362
Post Options Post Options   Thanks (0) Thanks(0)   Quote fernan82 Quote  Post ReplyReply Direct Link To This Post Posted: 02 June 2003 at 5:00pm

1. Add that domain to the blocked list...

2. Open register.asp

3. Change line 135 from:

blnEmailBlocked = False to: blnEmailBlocked = True

4. Change line 562 from:

If InStr(1, strEmail, strCheckEmailAddress, 1) Then blnEmailBlocked = True

to:

If InStr(1, strEmail, strCheckEmailAddress, 1) Then blnEmailBlocked = False

5. Save it.

I believe that should do it but i've never tried it so just give it a shot...

FeRnAN
Back to Top
lsabug View Drop Down
Newbie
Newbie


Joined: 02 June 2003
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote lsabug Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 11:16am

Many thanks fernan82. I just tried what you suggested and it seems to be working.

I really appreciate your help

 

Back to Top
lsabug View Drop Down
Newbie
Newbie


Joined: 02 June 2003
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote lsabug Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 11:26am

Oops, just one more thing keeps popping up.

Now that I've changed the registration to only allow one domain to register, everytime I test the registration form an error message comes up saying:

Sorry, the email address or domain entered has been blocked by the forum administrator

even though it's the allowable domain. When I close the error message I can still continue registering but I'm afraid it will confuse forum users if they see that message.

I'm not sure why this is happening. Is there another line I need to change?

Sorry to be a bugger.

lsa

Back to Top
vdub View Drop Down
Senior Member
Senior Member
Avatar

Joined: 23 February 2003
Location: United States
Status: Offline
Points: 275
Post Options Post Options   Thanks (0) Thanks(0)   Quote vdub Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 5:24pm
Just coment out the code that creates the popup.
Back to Top
fernan82 View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 17 November 2002
Location: United States
Status: Offline
Points: 362
Post Options Post Options   Thanks (0) Thanks(0)   Quote fernan82 Quote  Post ReplyReply Direct Link To This Post Posted: 03 June 2003 at 7:05pm

you can do that or change line 1163 from If blnUsernameOK = False OR blnEmailOK = False OR blnEmailBlocked = True Then %> to If blnUsernameOK = False OR blnEmailOK = False OR blnEmailBlocked = False Then %> and line 1179 from If blnEmailBlocked = True Then to If blnEmailBlocked = False Then

also search the whole file for blnEmailBlocked and whenever is followed by = False change it to = True and vice-versa...

<edit> also be careful when you do that search n replace, make sure you don't change back the lines you've already changed cuz that would mess it up and you might have to reupload a fresh copy of the file and start over....



Edited by fernan82
FeRnAN
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.