fix php example formatting

This commit is contained in:
Martin Cech 2015-06-24 11:03:35 -04:00
parent 8f42cb3ac3
commit aec331bf3b

View File

@ -10,16 +10,14 @@ Example Usage
PHP PHP
```php ```php
function is_temp_mail($mail) { function is_temp_mail($mail) {
$list = file_get_contents ('disposable_email_blacklist.conf');
$list = file_get_contents ('disposable_email_blacklist.conf'); $mail_domains_ko = explode("\n", $list);
$mail_domains_ko = explode("\n", $list); foreach($mail_domains_ko as $ko_mail) {
list(,$mail_domain) = explode('@',$mail);
foreach($mail_domains_ko as $ko_mail) { if(strcasecmp($mail_domain, $ko_mail) == 0){
list(,$mail_domain) = explode('@',$mail); return true;
if(strcasecmp($mail_domain, $ko_mail) == 0){
return true;
}
} }
}
return false; return false;
} }
``` ```