if (isset($_POST['lastdisplay'])) { $lastdisplay = strip_tags($_POST['lastdisplay']); } if (isset($_POST['statsreset'])) { $statsreset = strip_tags($_POST['statsreset']); } if (isset($_POST['active'])) { $active = strip_tags($_POST['active']); } if (isset($_POST['notes'])) { $notes = strip_tags($_POST['notes']); } if (isset($_POST['adid'])) { $adid = strip_tags($_POST['adid']); } qpe(&$title, &$banner, &$url, &$trackingurl, &$logfile, &$textad, &$textadurl, &$notes); //$domains = implode("|",$domains); if ($logtype != NULL) { $logtype = join(",", $logtype); } else { $logtype = ""; } //if (strtoupper($updmodifydate) == 'ON') $modifydate = strftime("%Y-%m-%d %H:%M:%S",time()); $now = strftime("%Y-%m-%d %H:%M:%S", time()); $iq = "update ads set " . "domains='{$domains}'," . "title='{$title}'," . "banner='{$banner}'," . "width='{$width}'," . "height='{$height}'," . "url='{$url}'," . "logfile='{$logfile}'," . "trackingurl='{$trackingurl}'," . "textad='{$textad}'," . "textadurl='{$textadurl}'," . "hits='{$hits}'," . "clicks='{$clicks}'," . "logtype='{$logtype}'," . "createdate='{$createdate}'," . "modifydate='{$now}'," . "expiredate='{$expiredate}'," . "lastdisplay='{$lastdisplay}'," . "statsreset='{$statsreset}'," . "active='{$active}'," . "notes='{$notes}'" . " where adid='{$adid}'"; if ($UserName != "testuser") { $qh = ad_query($iq); print mysql_error(); } $edit = ""; }
} if (!empty($edit)) { if ($B1 == "Update") { if (isset($_POST['name'])) { $name = strip_tags($_POST['name']); } if (isset($_POST['modifydate'])) { $modifydate = strip_tags($_POST['modifydate']); } if (isset($_POST['active'])) { $active = strip_tags($_POST['active']); } if (isset($_POST['updmodifydate'])) { $updmodifydate = strip_tags($_POST['updmodifydate']); } qpe(&$name, &$redir, &$logpath, &$notes); if (strtoupper($updmodifydate) == 'ON') { $modifydate = strftime("%Y-%m-%d %H:%M:%S", time()); } $iq = "update domains set " . "name='{$name}'," . "redir='{$redir}'," . "logpath='{$logpath}'," . "modifydate='{$modifydate}'," . "notes='{$notes}'," . "active='{$active}'" . " where domainid='{$edit}';"; ad_connect_db("db"); $qh = ad_query($iq); print mysql_error(); $new = FALSE; $edit = ""; } else { include "edit.domain.php"; } } else { show_domains(); }