Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Email Rules - Require that users' email addresses match a regular expression Details »
Email Rules - Require that users' email addresses match a regular expression
Mod Version: 1.0.0, by Analogpoint (Member) Analogpoint is offline
Developer Last Online: Dec 2007 I like it Show Printable Version Email this Page

vB Version: 3.6.8 Rating: (5 votes - 5.00 average) Installs: 22
Released: 15 Oct 2007 Last Update: Never Downloads: 99
Not Supported Uses Plugins  

This modification simply requires a user's email address to match a regular expression that you specify in the admin control panel options. vBulletin already has an email banning function where you can ban different emails and email providers. This mod lets you do the opposite-- require a certain type of email address. For example you could require that all users have a .edu address.

Requested here.

Installation: Unzip the attached file and import the .XML file in the Product Manager in the Admin Control Panel. Then visit the 'Email Rules' options page in vBulletin Options to set up your regular expression.

This mod add two plugins, that's it.

Download Now

Only licensed members can download files, Click Here for more information.

Screenshots

Click image for larger version

Name:	screenshot1.png
Views:	432
Size:	31.0 KB
ID:	71068  

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 16 Oct 2007, 00:17
SMO's Avatar
SMO SMO is offline
 
Join Date: Sep 2005
Real name: Geoff
wow...this is a very good idea. Making it easy for users to register from a certain "realm"

I was trying to think on how to do this with making a military only forum.
Reply With Quote
  #3  
Old 16 Oct 2007, 00:31
yoyoyoyo's Avatar
yoyoyoyo yoyoyoyo is offline
 
Join Date: Dec 2004
can you specify more than one rule?
Reply With Quote
  #4  
Old 16 Oct 2007, 21:02
Analogpoint's Avatar
Analogpoint Analogpoint is offline
 
Join Date: Feb 2007
Originally Posted by yoyoyoyo View Post
can you specify more than one rule?
Yes, you specify just one regular expression, but you can have unlimited rules within it. If you need help with a regular expression, just post here explaining what you're trying to accomplish, and I'll try to help.

Also, this website will help get you up to speed on regexes http://www.regular-expressions.info/
__________________
My vBulletin Modifications.
Reply With Quote
  #5  
Old 28 Jan 2008, 19:10
Crazy Serb Crazy Serb is offline
 
Join Date: Mar 2005
ok, so if I want to add a few email addresses into the regex field, how would I do it?

let's say, I only want to allow gmail.com, hotmail.com and yahoo.com as valid emails... how do I write that out?
Reply With Quote
  #6  
Old 29 Feb 2008, 16:48
Crazy Serb Crazy Serb is offline
 
Join Date: Mar 2005
ok, so I put the following in the rules field:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

and some users who tried to register with hotmail.com emails still can't get past the script and keep getting error messages... how?! what's wrong here?
Reply With Quote
  #7  
Old 23 May 2008, 19:35
MISTER2 MISTER2 is offline
 
Join Date: Feb 2007
Awesome, installed on 3.7.0 tested and it works great!
(Tested with single domain restriction)

Last edited by MISTER2; 23 May 2008 at 19:43.
Reply With Quote
  #8  
Old 19 Sep 2008, 06:29
biome.pat biome.pat is offline
 
Join Date: Aug 2008
Real name: Patrick Connolly
Alright, so I think I've found a bug.

If you run a board where you want to prevent users from changing their email, either by editing the modifypassword template or by cutting things out of the profile.php file (tried many things, like changing $show['edit_email_field'] to false whether user was on ban list or not, and commenting out whole sections). Anyhow, regardless of how I tried to work it, I couldn't remove the email input fields, because when users tried to change their passwords, they'd be redirected to error pages saying they needed to enter their email (when those spaces didn't exist).

And when I disabled Email Rules, everything worked fine.

Any ideas? Suggestion would be muchly appreciated!
Reply With Quote
  #9  
Old 19 Sep 2008, 06:32
biome.pat biome.pat is offline
 
Join Date: Aug 2008
Real name: Patrick Connolly
Ah... and I'm an idiot. If anyone else has this problem, just hack out the fields any way you please, and turn off the plugin at the profile_updatepassword_complete hook... Who needs that when there isn't any way to change it...

Grrr...

Well, so long as others can learn from my mistakes!
Reply With Quote
  #10  
Old 24 Jul 2009, 20:02
IDEASBANK2009 IDEASBANK2009 is offline
 
Join Date: Jul 2009
HOW SWEET IS THAT!!!!
Great job and thanks again!
IDEASBANK2009
Reply With Quote
  #11  
Old 23 Jul 2011, 02:38
ilanyon ilanyon is offline
 
Join Date: Nov 2005
Real name: Ian
vB 4.x.x compatability?

Hi, has anyone tried this with vB 4?

Or know of anything that does work with such???

Much appreciated,

Ian
Reply With Quote
  #12  
Old 29 Jul 2011, 03:51
bbi bbi is offline
 
Join Date: Jul 2011
I am also curious - does this work with VB 4?
Thanks
Reply With Quote
  #13  
Old 29 Oct 2011, 19:04
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
It works for me on VB 4.1.7.
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #14  
Old 06 Feb 2012, 12:15
oldlock oldlock is offline
 
Join Date: Jul 2009
Anyone have any insights how one could use this like :

allow any .gov address, but also overseas .gov, like .gov.uk, .gov.ie etc. Basically to ensure that there has to be .gov somewhere in the address ???
Reply With Quote
  #15  
Old 06 Feb 2012, 13:00
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
this should do it:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 12:30.

Layout Options | Width: Wide Color: