This extension is a small modification of the original CEmailValidator class. I've build in a top-level-domain check based on the offical list available here.
Resources ¶
Documentation ¶
Requirements ¶
- Yii 1.0 or above
Installation ¶
- Extract the release file under
protected/extensions
Usage ¶
Check examples in The Definitive Guide to Yii
Things to mention ¶
Since the top-level-domains will get fetched from an external source, you have to define a cache component in the config in order to use this extension. cacheID
defaults to "cache".
The tld's will get cached for 24 hours. If they couldn't get fetched from iana.org for some reason, we use a fallback pattern to validate an email address. This fallback pattern works basically like the one from the original CEmailValidator class. It will get cached for 1 hour - we don't want to flood iana.org =)
I have removed the fullPattern
and allowName
attributes from the original class since I've not get it to work properly.
I may update this extension from time to time for some enhancements.
Change Log ¶
January 6, 2010 ¶
- Initial release.
If you have any questions, please ask in the forum instead.
Signup or Login in order to comment.