HTMLPurifier 4.4.0
/home/ezyang/Dev/htmlpurifier/library/HTMLPurifier/URIScheme/mailto.php
Go to the documentation of this file.
00001 <?php
00002 
00003 // VERY RELAXED! Shouldn't cause problems, not even Firefox checks if the
00004 // email is valid, but be careful!
00005 
00012 class HTMLPurifier_URIScheme_mailto extends HTMLPurifier_URIScheme {
00013 
00014     public $browsable = false;
00015     public $may_omit_host = true;
00016 
00017     public function doValidate(&$uri, $config, $context) {
00018         $uri->userinfo = null;
00019         $uri->host     = null;
00020         $uri->port     = null;
00021         // we need to validate path against RFC 2368's addr-spec
00022         return true;
00023     }
00024 
00025 }
00026 
00027 // vim: et sw=4 sts=4