From 7e0b0f477355b7f16a609fba099b422cbd3d381f Mon Sep 17 00:00:00 2001 From: laf Date: Tue, 24 Jun 2014 16:14:42 +0100 Subject: [PATCH] Created validate_device_id() function --- includes/functions.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/includes/functions.php b/includes/functions.php index 4ab9d9d83..8b6352ffa 100755 --- a/includes/functions.php +++ b/includes/functions.php @@ -916,4 +916,19 @@ function scan_new_plugins() } +function validate_device_id($id) +{ + + global $config; + $device_id = dbFetchCell("SELECT `device_id` FROM `devices` WHERE `device_id` = ?", array($id)); + if($device_id == $id) + { + $return = true; + } + else + { + $return = false; + } + return($return); +} ?>