<?php
 
 
   // this sample has an error caused by a wrong interface
 
 
   include_once 'InputValidator.php';
 
  
 
  $data = array(
 
          "data" => array(
 
            "is_active" => true,
 
            "name" => "asd",
 
            "firstname" => "Schaefer",
 
            "born_at" => "2012",
 
            "gender" => "1",
 
            "address" => array(
 
              "city" => "Erftstadt",
 
              "zip" => "50374",
 
              "phone" => "0049555123456"
 
            ),
 
          )
 
      );
 
    
 
 
  $check = InputValidator::validate($data, dirname(__FILE__)."/test.xsd");  
 
  if($check){
 
    print_r($check);  
 
  } else {
 
    echo "valid";
 
  }
 
  
 
  
 
 
 |