Skip to main content
Topic: Possible to limit registration to a specific set of email addresses? (Read 2336 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Possible to limit registration to a specific set of email addresses?

I have a specific group that will be allowed to post in our forum and I'm wondering if it's possible to basically create a whitelist of email addresses that are allowed to register and disallow all others.

Thanks much!


Re: Possible to limit registration to a specific set of email addresses?

Reply #1

No direct ways that I could remember.
In theory, you could use a trick and set up a custom field validating the content with a regexp set to accept only certain emails. Of course it would just be a trick, because it wouldn't be the real email, but just a dummy field.
Bugs creator.
Features destroyer.
Template killer.

Re: Possible to limit registration to a specific set of email addresses?

Reply #2

If you can do some basic programming ... I think you could use this addon: http://addons.elkarte.net/admin/Block-Disposable-Email.html 

You would have to replace the dea_validate_email() function to allow only emails from the domain that you want.

Re: Possible to limit registration to a specific set of email addresses?

Reply #3

Thanks guys, I appreciate the response and ideas. If I end up doing any custom programming, I'll post back here. For now, it's 136 different email addresses, each a different domain, and we have the list and will just manually compare each signup and verify. Since it's really a one-time deal, it doesn't need a full-on programming effort. I was just wanting to make sure I wasn't missing anything that was already built in to do something like this. Onward! :)

Re: Possible to limit registration to a specific set of email addresses?

Reply #4

Quote from: tcultech – ...if it's possible to basically create a whitelist of email addresses that are allowed to register and disallow all others..
Change the E-MailBan to the opposite!
http://www.elkarte.net/community/index.php?topic=801.msg5656#msg5656

Greetz
NetFlag

Re: Possible to limit registration to a specific set of email addresses?

Reply #5


@NetFlag  That's perfect, thanks!!

Re: Possible to limit registration to a specific set of email addresses?

Reply #6

@NetFlag I'm trying to implement your solution, but the allowed email addresses (146 of them) are each from different domains. I wonder if I can paste the list into that ban field comma delimited? I'll try it and let you all know. THis is a forum for 135 companies and each company is allowed to have only one representative register from their domain.

Thanks!

Re: Possible to limit registration to a specific set of email addresses?

Reply #7

OK, it looks like the email ban requires a *.domain.xxx format and not a specific email address or addresses?

Not sure where I would add my list of allowed registrants, but if there's an easy way and you all can see it, (I'm just missing it!) I'd love to hear. If not, no worries, I'll just let this go until later, but again, thanks for your help/response—much appreciated.

Re: Possible to limit registration to a specific set of email addresses?

Reply #8

If you have the list you can insert them directly into the database:
Code: [Select]
INSERT INTO elkarte_ban_items (id_ban_group, email_address)
VALUES (**BANGROUP**, '*.domain.xxx'),
(**BANGROUP**, '*.anotherdomain.yyy')
And so on, just make the list longer with the comma at the end of each line except the last one.

The only thin is find the bangroup, that you can find editing the ban and looking at the url, it should look like:
Code: [Select]
http://www.domain.tld/index.php?action=admin;area=ban;sa=edit;bg=2
that number at the end (2 in this case) is the bangroup, so the query above would become:
Code: [Select]
INSERT INTO elkarte_ban_items (id_ban_group, email_address)
VALUES (2, '*.domain.xxx'),
(2, '*.anotherdomain.yyy')
Bugs creator.
Features destroyer.
Template killer.