PX : code

XML VIN Decoder by Jock Pereira
Download this code


<?php
// this code accesses the best of class car, truck and motorcycle vin decoder on DataOne Software servers.
// visit http://dataonesoftware.com/heart.php?setminor=3387 or call 877-438-8467 to get further information on this easy to integrate vin decoder

$base         'http://xmlvindecoder.com/harnessXML/harnessRest5.php';
$query_string '';

$params = array( 'clientName' => "yournamehere",
    
'vinNumbers'  => 'WDBJF72F7VA387966',
    
'bodyStyles'  => '',
    
'accessCode'  => 'accesscodehere',
);

foreach (
$params as $key => $value) { 
    
$query_string .= "$key=" urlencode($value) . "&";
}

$url "$base?$query_string";

$cobj=curl_init($url);
$r=curl_setopt($cobj,CURLOPT_RETURNTRANSFER,1);
$xml=curl_exec($cobj);
$r=curl_close($cobj);
echo 
$xml;
?>

Comments or questions?
PX is running PHP 5.2.17
Thanks to Miranda Productions for hosting and bandwidth.
Use of any code from PX is at your own risk.