Login   Register  
PHP Classes
elePHPant
Icontem

File: vat_test.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Benjamin Boigienman  >  VAT Checker  >  vat_test.php  >  Download  
File: vat_test.php
Role: Example script
Content type: text/plain
Description: Test
Class: VAT Checker
Check if a European VAT number is valid
Author: By
Last change:
Date: 2005-05-04 01:49
Size: 260 bytes
 

Contents

Class file image Download
require_once("vatchecker_class.php");

$vat = new VATChecker("data_vat.xml", "error_vat.xml", "fr");

$vatno = "FR88 331 121 327";

if($vat->check($vatno))
    echo "numéro valide (".ucfirst($vat->getPays($vatno)).")";
else 
    echo $vat->getLastError();