From 09905501339d3b50d01143b1ee31eead2dc5f192 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Sun, 10 Jul 2005 19:24:45 +0000 Subject: [PATCH] r298: - Removed datelike() [includes/functions.php] - Switching to TIMENOW for inserts and updates in queries instead of time() --- attachment.php | 2 +- includes/functions.php | 13 ------------- newcomment.php | 2 +- newreport.php | 2 +- 4 files changed, 3 insertions(+), 16 deletions(-) diff --git a/attachment.php b/attachment.php index fc9d025..6e07e34 100755 --- a/attachment.php +++ b/attachment.php @@ -105,7 +105,7 @@ if ($_POST['do'] == 'insert') } $filedata = $bugsys->escape(file_get_contents($FILE['tmp_name']), true, true); - $time = time(); + $time = TIMENOW; // insert an attachment $db->query(" diff --git a/includes/functions.php b/includes/functions.php index d2ef4fd..15cbbfa 100755 --- a/includes/functions.php +++ b/includes/functions.php @@ -38,19 +38,6 @@ function construct_option_select($name, $array, $selected = 0, $valuekey = '', $ return '"; } -// ########################## Start datelike ######################### -function datelike($format, $timestamp) -{ - global $bugsys; - - if (!$format OR $format == 'standard') - { - $format = $bugsys->options['dateformat']; - } - - return date($format, ($timestamp + (60 * $bugsys->userinfo['timezone']))); -} - // ################### Start construct_user_display ################## // $userinfo needs userid, email, displayname, and showemail function construct_user_display($userinfo, $userid = true) diff --git a/newcomment.php b/newcomment.php index 8f391fc..fcdb10d 100644 --- a/newcomment.php +++ b/newcomment.php @@ -39,7 +39,7 @@ if ($_POST['do'] == 'insert') $bugsys->in['comment_parsed'] = $bugsys->sanitize($bugsys->in['comment_parsed']); } - $time = time(); + $time = TIMENOW; $db->query(" INSERT INTO " . TABLE_PREFIX . "comment diff --git a/newreport.php b/newreport.php index 1c75133..766be86 100755 --- a/newreport.php +++ b/newreport.php @@ -112,7 +112,7 @@ if ($_POST['do'] == 'insert') $bugid = $db->insert_id(); - $time = time(); + $time = TIMENOW; // insert the comment to the database $db->query(" -- 2.22.5