| Server IP : 10.200.247.200 / Your IP : 216.73.217.19 Web Server : Apache System : Linux synergy-usa-sites 6.8.0-138-generic #138-Ubuntu SMP PREEMPT_DYNAMIC Fri Jul 31 22:41:49 UTC 2026 x86_64 User : jeremy ( 1001) PHP Version : 8.4.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/usa_sites/usafundingapplications.org/vsa/ |
Upload File : |
<?php
/*
Copyright (c) 2007-present InnAnTech Industries
Author: Dave Guindon
Web: www.VirtualSmartAgent.com
Support: www.DaveGuindonSupport.com
Please send bug reports, suggestions and/or feedback to the support
website given above.
Virtual Smart Agent is a commercial software. Any distribution is strictly prohibited
unless a resale rights license was delivered along with this software.
*/
$lid = $_GET['lid'];
$cid = $_GET['cid'];
$aid = $_GET['aid'];
$cli = $_GET['cli'];
$pid = $_GET['pid'];
$testmode = $_GET['tmd'];
if ((isset($lid))&($lid!='')){
include('modfiles/db.php');
//get ip address here
$ip = $_SERVER['REMOTE_ADDR'];
//get todays date
$dtoday = time();
//connect to the database
$conn = mysql_connect("$dbhost", "$dblogin", "$dbpass") or die ('I cannot connect to the database.');
mysql_select_db($dbname, $conn);
//check for testmode
$result = mysql_query("SELECT * FROM $campaignTable WHERE id='$cid'",$conn);mysql_error()?(print(mysql_error())):'';
$camp = mysql_fetch_assoc($result);
if (($camp['testmode'] == '0')&&($testmode == '0')){
//set cookies to track sales in sale.php
setcookie("vsa_lid".$cid, $lid, time()+60*60*24*100, "/");
setcookie("vsa_aid".$cid, $aid, time()+60*60*24*100, "/");
setcookie("vsa_cli".$cid, $cli, time()+60*60*24*100, "/");
setcookie("vsa_pid".$cid, $pid, time()+60*60*24*100, "/");
//insert this click into the links data table
$sql = "INSERT INTO $linksdataTable VALUES(null,'$cid','$lid','$aid','$cli','$ip','$dtoday')";
mysql_query($sql,$conn);mysql_error()?(print(mysql_error())):'';
//update this chat log with link followed
//NEW update the chatend for all interactions for the case when closing doesn't work
$sql = "UPDATE $chatlogTable SET action='operation', chatend='$dtoday' WHERE id='$cli' AND cid='$cid'";
mysql_query($sql,$conn);mysql_error()?(print(mysql_error())):'';
}//end testmode
//now get the destination url and redirect
$sql = "SELECT * FROM $linksTable WHERE id='$lid'";
$result = mysql_query($sql,$conn);mysql_error()?(print(mysql_error())):'';
$ldata = mysql_fetch_assoc($result);
$url = $ldata['link'];
//finally redirect here
header('location: '.$url);
exit;
}else{
echo "There was no link id given. Contact support.";
}
?>