E-mail Address Restrictions [Deleted]

alexD

Well-known member
alexD submitted a new resource:

E-mail Address Restrictions - Whitelist / Blacklist e-mail hosts.

Allow only specific e-mail hosts to be used in e-mails or disallow others.

This add-on works not only on user registration but on other pages such as the user's Contact Details page, when a user modifies their e-mail.
Administrators can still bypass the e-mail restrictions when editing users via the Admin Control Panel.

This add-on is sponsored by Case.

Please let me know if you encounter any issues or have found it useful!

Read more about this resource...
 
Hi,

I have a problem with this add-on, when Im putting some domains name in Whitelisting, nothing happens, and everyone can register. I want to give access just to users who are using yahoo as their email address.

I cleaned the whole of the list and filed the yahoo.com in host field (Whitelisting), but when I tried to register with a gmail email address nothing happened and I registered without any error!

could you please guide me?

Thanks
 
You know, its none scene, cause when i'm saying this address is in white list, it means any other addresses automatically are in black list.

P.S: I checked it again, same addresses are in both blacklist and whitelist by default.
 
Not sure if it works like this.
Maybe need blacklist.

But this can answer only the developer.
You can only have one or they other, look at the screenshot you have the choice between "white list" and "black list" so opting to choose the former would mean only those on that list can register.
 
There is a phrase you can already use and modify to your liking @Nirjonadda

Considering you have already whitelisted the yahoo, gmail and hotmail domains above, you can always edit the 'email_address_not_in_whitelist' phrase.

If a user tries to submit their registration form using a not whitelisted email host, they're going to get an error alike the Duplicate Username error we see in your screenshot (but near the email input now and with the error text you have set instead).
 
'email_address_not_in_whitelist'

Not this phrase, This phrase are used for AJAX email address check. If a user tries to submit their registration form using a not whitelisted email host, they're going to get an error alike the Duplicate Username error.

I am asked for adding some Details under Email box filed that show what type email address are allowed for Registration?

f97b98794aa84916889e71e2bc779157.png
 
Last edited:
That is probably out of the scope of this add-on.

To add something like what you're asking, you should:
1) Start editing the 'register_form' template.
2) Find
Code:
	<dl class="ctrlUnit">
	<dt><label for="ctrl_{$fieldMap.email}">{xen:phrase email}:</label></dt>
	<dd>
		<input type="email" name="{$fieldMap.email}" value="{$fields.email}" dir="ltr" class="textCtrl" id="ctrl_{$fieldMap.email}" />
	</dd>
	</dl>
And replace with
Rich (BB code):
	<dl class="ctrlUnit">
	<dt><label for="ctrl_{$fieldMap.email}">{xen:phrase email}:</label></dt>
	<dd>
		<input type="email" name="{$fieldMap.email}" value="{$fields.email}" dir="ltr" class="textCtrl" id="ctrl_{$fieldMap.email}" />
		<p class="explain">You can only register from the following email domains: @yahoo.com @gmail.com @hotmail.com</p>
	</dd>
	</dl>
 
@alexD, I have added some Best email service in my Whitelisting, Do this adding are correct and I am missed adding more email in my Whitelisting? Do we need adding more email service in my Whitelisting?

Code:
yahoo.com
gmail.com
icloud.com
outlook.com
hotmail.com
aol.com
aim.com
zoho.com
mail.com
protonmail.com
gmx.com

69103f00dfd1428cb765f1c23f3ee501.png
 
Top Bottom