PHP Classes

File: test_mailinglist_sanitizer.php

Recommend this page to a friend!
  Classes of zinsou A.A.E.Moïse   PHP Mailing List Sanitizer   test_mailinglist_sanitizer.php   Download  
File: test_mailinglist_sanitizer.php
Role: Example script
Content type: text/plain
Description: example script
Class: PHP Mailing List Sanitizer
Validate a list of email addresses
Author: By
Last change:
Date: 6 years ago
Size: 1,404 bytes
 

Contents

Class file image Download
<html>
<head>
<title>Test for PHP MailingList Sanitizer</title>
</head>
<body>
<h1 align="center">Test for PHP MailingList Sanitizer</h1>
<hr>
<?php
   
require_once('EmailChecker.class.php');
   
$x=new EmailChecker();
    echo
'<pre>';
    echo
'<h2>Uploaded file</h2>';
    if( isset(
$_POST ) && $_SERVER['REQUEST_METHOD'] == 'POST' ) {
       
print_r($x->Uprocess(time().'.csv'));//uploaded file sanitizer...sanitize and save to timestamp.csv(you can choose your own name provided that the file doesn't exist)
   
}
   
   

?>
<form method="post" enctype="multipart/form-data">
        <input type="file" name="file">
        <input type="submit" value="Submit">
    </form>
<?php
/*
        echo '<h2>Local File</h2>';
        print_r($x->LFprocess('r.csv',time().'.csv'));//local file sanitizer...sanitize and save to timestamp.csv(you can choose your own name provided that the file doesn't exist)
       
       
        echo '<h2>Data in Array</h2>';
        $ar=array('leizmo@gmail.com','corzinsou@gmail.com','mosewinsou@yul.com','schneider@machin.net','moinsou@yahoo.com');
        print_r($x->ARprocess($ar,time().'.csv'));//array sanitizer...sanitize and save to timestamp.csv(you can choose your own name provided that the file doesn't exist)
*/
       
echo'</pre>';
       
       
//ps: Omitting the parameter name will make all the functions just return the array of valid and broken and avoid saving in file.
?>
<hr>
</body>
</html>