From ee02363d07131379c1e2537cffa20c453f596cad Mon Sep 17 00:00:00 2001 From: Liam McLoughlin Date: Sat, 6 Aug 2011 00:37:00 +0100 Subject: Add email notification support --- web/process.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'web/process.php') diff --git a/web/process.php b/web/process.php index c590bee..de8ea90 100644 --- a/web/process.php +++ b/web/process.php @@ -62,6 +62,7 @@ $features = filter_input(INPUT_POST, "features", FILTER_CALLBACK, $sfi); $keywords = filter_input(INPUT_POST, "keywords", FILTER_CALLBACK, $sfi); $outputFormat = filter_input(INPUT_POST, "format", FILTER_CALLBACK, $sfi); + $email = filter_input(INPUT_POST, "email", FILTER_VALIDATE_EMAIL); $iniString = "[vmconfig] @@ -97,10 +98,10 @@ OUTPUT_FORMAT=$outputFormat"; die("Could not connect to database ".mysqli_connect_error()); } - $query = "INSERT INTO builds (id, handle, ipaddress) ". - "VALUES(?, ?, ?)"; + $query = "INSERT INTO builds (id, handle, ipaddress, email) ". + "VALUES(?, ?, ?, ?)"; $stmt = $db->prepare($query); - $stmt->bind_param("sss", $buildID, $handle, $ipaddress); + $stmt->bind_param("ssss", $buildID, $handle, $ipaddress, $email); $stmt->execute(); $stmt->close(); $db->close(); -- cgit v1.2.3-65-gdbad