Thanks Liran,
All I want to do is pass these variables to a Lightbox which will have the code to interpret the values and print the results. FYI Here is the pertinent C-language code snipits this does this in the old website.
int chev;
int i;
int iyear;
int year_sw;
char gm_division[10];
char vega_nameplate[5];
char body_style[20];
char body_type[20];
char bs_code[3];
char year_code[4];
char year[4];
char vin[8];
char num[8];
long prod_num;
t show_results() {
/* decode VIN */
for(i=0;i<6;i++) {
num[i]=vin[i];
}
prod_num=atoi(num);
prod_num=prod_num-100000;
/* print summary */
printf(“
The VIN Tag information you provided decodes as follows:
\n”);
printf(“\n”);
printf(“ \n”);
printf(“ \n”);
printf(" \n",entries[12].val);
printf(“\n”);
printf(“
<font face="arial narrow",helvetica size=4>%s\n",entries[0].val);
printf(" %s\n",entries[1].val);
printf(" %s\n",entries[2].val);
printf(" %s\n",entries[3].val);
printf(" %s\n",entries[4].val);
printf(" %s\n",entries[5].val);
printf(" %s\n",entries[6].val);
printf(" %s\n",entries[7].val);
printf(" %s\n",entries[8].val);
printf(" %s\n",entries[9].val);
printf(" %s\n",entries[10].val);
printf(" %s\n",entries[11].val);
printf(" %s |
---|
\n”);
printf(“\n”);
printf("
This Tag is/was originally affixed to a %d Chevrolet Motor Division %s ",year_sw,body_type);
printf(“body assembled at Lordstown, OH. The Lordstown factory installed a Cosworth Vega engine that had been \n”);
printf(“assembled in Tonawanda, NY into this body. It then built this vehicle as a Cosworth Vega model.\n”);
printf(“
It was the number %d Vega built for this production year.
\n”,prod_num);
if(year_sw == 1975) {
printf(“The Lower Left Corner of the BODY TAG of this car should read: %sC.\n”,vin);
}
else {
printf(“The Lower Left Corner of the BODY TAG of this car should read: %sC90.\n”,vin);
}
}
int decode_id() {
printf(“
Thank You, Here Are The Decode Results
”);
if(num_entries <13) {
printf(“Error! You failed to complete all the input boxes.\n”);
printf(“Please hit the back button and try again.
\n”);
print_tail();
return(0);
}
chev=atoi(entries[0].val);
if(chev == 1) {
strcpy(gm_division,“Chevrolet”);
}
else {
printf(“Error! You entered %d for the YEAR.
\n”,chev);
printf(“This decoder only works with 75 or 76 Chevrolet Vegas
Please hit the back button and try again.
\n”);
print_tail();
end_session();
exit(0);
}
/* BODY TYPE */
if(entries[1].val[0] == ‘V’) {
strcpy(body_type,“Vega”);
}
else {
printf(“Error! You entered %s for the YEAR.
\n”,entries[1].val);
printf(“The ONLY valid body type for Vega is "V".
Please hit the back button and try again.
\n”);
print_tail();
end_session();
exit(0);
}
/* BODY STYLE */
strcpy(bs_code,entries[2].val);
strcat(bs_code,entries[3].val);
if(!strncmp(bs_code,“77”,2)) {
strcpy(body_style,“2 Door Hatchback Coupe”);
}
else {
printf(“Error! You entered %s for the body style.
\n”,bs_code);
printf(“The ONLY valid body type for Vega is "77".
Please hit the back button and try again.
\n”);
print_tail();
end_session();
exit(0);
}
/* YEAR */
strcpy(year_code,entries[4].val);
strcat(year_code,entries[5].val);
strcat(year_code,entries[6].val);
if(!strcmp(year_code,“O6U”)) {
year_sw=1976;
}
else {
if(!strcmp(year_code,“E5U”)) {
year_sw=1975;
}
else {
year_sw=0;
}
}
switch(year_sw) {
case 1976: strcpy(year,"1976");
break;
case 1975: strcpy(year,"1975");
break;
default: printf("Error! The value <font color=red> <b> %s </font></b> is not a valid code.<p>\n",year_code);
printf("Please hit the back button and try again.<p>\n");
print_tail();
end_session();
exit(0);
}
/* UNIT_NO */
strcpy(vin,entries[7].val);
strcat(vin,entries[8].val);
strcat(vin,entries[9].val);
strcat(vin,entries[10].val);
strcat(vin,entries[11].val);
strcat(vin,entries[12].val);
}
i
int show_tag() {
printf(“\n”);
printf(“
\n”);
printf(“\n”);
printf(“\n”);
printf(“ \n");
printf(“ \n”);
printf(“\n”);
printf(“ \n”);
printf(" \n");
printf(“\n”);
printf(“\n”);
printf(" \n");
printf(“\n”);
printf(“\n”);
printf(“\n”);
printf(" \n");
printf(“\n”);
printf(“\n”);
printf(" \n");
printf(“\n”);
printf(“\n”);
printf(" \n");
printf(“\n”);
printf(“
<font face="arial narrow",helvetica size=2>BODY BY FISHER \n”);
printf("
|
<font face="arial narrow",helvetica size=4>ST\n");
printf(" \n");
printf(" %s",entries[0].val);
printf(" 1 \n");
printf(" %s",entries[1].val);
printf(" %s",entries[2].val);
printf(" U\n");
printf(" \n");
printf(" %s",entries[3].val);
printf(" BDY\n");
printf(" \n");
printf(" |
<font face="arial narrow",helvetica size=4>TR\n");
printf(" \n");
printf(" %s",entries[4].val);
printf(" \n");
printf(" %s",entries[5].val);
printf(" \n");
printf(" %s",entries[6].val);
printf(" \n");
printf(" %s",entries[7].val);
printf(" PNT\n");
printf(" \n");
printf(" |
<font face="arial narrow",helvetica size=4>\n");
printf(" \n");
printf(" %s",entries[8].val);
printf(" \n");
printf(" \n");
printf(" 78-3593\n");
printf(" \n");
printf(" |
<font face="arial narrow",helvetica size=4>\n");
printf(" \n");
printf(" %s",entries[9].val);
printf(" \n");
printf(" FUL\n");
printf(" \n");
printf(" |
<font face="arial narrow",helvetica size=2>GENERAL MOTORS CORPORATION \n");
printf(" CERTIFIES TO THE DEALER THAT THIS \n");
printf(" VEHICLE CONFORMS TO ALL U.S. FEDERAL \n");
printf(" MOTOR VEHICLE SAFETY STANDARDS \n");
printf(" APPLICABLE AT TIME OF MANUFACTURE\n");
printf(" \n");
printf(" |
\n”);
}