#!/usr/local/bin/perl ############################################################################################ # SalesDoubler Version 1.3 COPYRIGHT ©1999, Commercial Networks Inc., CommercialNetworks.com ############################################################################################ # Do not remove. # This script is part of SalesDoubler set of scripts. # For more info about SalesDoubler send email to: info@commercialnetworks.com # This script is licenced to be used on heart-of-asia.org server only. # Permission to modify this script is granted only on heart-of-asia.org server. # Any other distribution or use of this script will be considered as a # copyright infringement. require 'cgi-lib.pl'; require 'setup.pl'; &ReadParse(*input); print &PrintHeader; # writing log record ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday) = localtime(time); $mon++; if($mon>12) {$mon=1;}; if($min<10) {$min='0'.$min;}; if($sec<10) {$sec='0'.$sec;}; if($input{page} eq "") { $input{page} = "index"; } if( ($input{country} ne "asia") && ( $input{country} ne "europe") && ( $input{country} ne "least") && ( $input{country} ne "merica")) { $input{country} = ""; } else { $input{country} = "$input{country}/"; } if($input{dealer} eq "") { $input{dealer} = "1"; } if($input{sub} eq "") { $input{sub} = "index"; } #get dealers email open(DATA,"$data_path/users.dat") || &CgiDie("Can't open #5"); while($_=) { chop(); @from_db = split(/\|/,$_); if($from_db[0] eq $input{dealer}) { $in_email = $from_db[7]; $in_image = $from_db[13]; } } close(DATA); if($in_image ne "") { $logo = ""; } else { $logo = ""; } open(HTML,"$html_path/$input{page}".".html"); while($_=) { s/%%DEALER/$input{dealer}/g; s/%%COUNTRY/$input{country}/g; s/%%SUB/$input{sub}/g; s/%%EMAIL/$in_email/g; s/%%IMAGE/$image_path/g; s/%%BASE/$scriptbase/g; s/%%SBASE/$secure/g; s/%%HTML/$html_path/g; s/%%LOGO/$logo/g; print $_; } close(HTML);