more about
MONTH OF PRODUCTION
(click Sample)
STEP1
Register
and
Buy package
no monthly payments
only packages
STEP2 username
password
STEP3
Save as /month.php
Month of production
'; $vendor = isset($_POST['vendor']) ? $_POST['vendor'] : $defaultVendor; $chassis = isset($_POST['chassis']) ? $_POST['chassis'] : $defaultChassis; echo '
'; foreach($VENDORS as $val) { $selected = ($val === $vendor) ? ' selected="selected"' : ''; echo '
'.strtoupper($val).'
'; } echo '
'; } function validateInput($vendor, $chassis) { global $VENDORS; if (!in_array($vendor, $VENDORS)) { die('Invalid vendor selected'); } if (!preg_match("/^[a-zA-Z0-9]+-[\d]+$/", $chassis)) { die('Invalid chassis format. Expected format: ABC123-456789'); } if (strlen($chassis) < 8) { die('Chassis number too short'); } } function displayResults($vendor, $chassis) { global $ACCESS_CODE; $url = API_BASE_URL.'?json&vendor='.urlencode($vendor).'&body='.urlencode($chassis).'&user='.urlencode($ACCESS_CODE); echo '
API URL:
'.htmlspecialchars($url).'
'; $json = file_get_contents($url); if ($json === false) { echo '
Error: Failed to fetch data from API
'; return; } $data = json_decode($json, true); if (json_last_error() !== JSON_ERROR_NONE) { echo '
Error: Invalid JSON response (code: '.json_last_error().')
'; return; } $highlightFields = array('year', 'month', 'balance'); foreach($data as $key => $value) { $class = in_array($key, $highlightFields) ? 'highlight' : ''; echo '
' .htmlspecialchars($key).': '.htmlspecialchars($value) .'
'; } } // FORM renderForm(); // MONTH OF PRODUCTION if (isset($_POST['chassis'])) { validateInput($_POST['vendor'],$_POST['chassis']); displayResults($_POST['vendor'],$_POST['chassis']); } ## YEAR - year ## MONTH - the month of production ## MODELCODE - model code ## COLORCODE - color of the body ## TRIMCODE - color of the salon ## JAPANVDS - identification number (VDS) ## CATALOGNO - catalogue number ## ENGINENO - engine ## ENGINECODE - engine's options ## BODYCODE - body type ## GRADECODE - modification ## GRADEDESC - description of update ## TRANSCODE - transmission ## MODELNAME - model name ## COMPATIBLEFRAME - compatible body ## FRAMEYEAR - year of the numbering plan ## FRAMEMONTH - the month of production on the numbering plan ## CODE - advanced ## TRANSTYPE - description of transmission ## DOORSTYLE - doorstyle ## FRAMECODE - description of the body ## SPEC - spec. equipment