<?Php
 
$url_ok = "$PHP_SELF";
 
$head = "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n\n"
 
       ."<html>\n<head>\n\t<TITLE>Example Validate Form</TITLE>\n</head>\n<BODY>\n";
 
$foot = "\n</body>\n</html>\n";
 
// set in the array to 1 for enable or to 0 for hidden the field
 
$label = array('lang'=>'it','username'=>'1','email'=>'1','password'=>'1','password2'=>'1','name'=>'0','url'=>'0','age'=>'0','select'=>'0');
 
if(!isset($go)) {
 
    include("./validate.class.php");
 
    $obj = new Validate_Form;
 
    $obj->set_head($head);
 
    $obj->set_foot($foot);
 
    $obj->set_url($url_ok);
 
    $obj->set_label($label);
 
    if(!isset($ok)) $obj->make_form();
 
    else $obj->check_form($l,$username,$email,$password,$password2,$name,$url,$age);
 
} else {
 
    echo $head;
 
    echo "OK";
 
    echo $foot;
 
}
 
?>
 
 |