return $d->format('c');
}
+function common_sql_now() {
+ return strftime('%Y-%m-%d %H:%M:%S', time());
+}
+
function common_redirect($url, $code=307) {
static $status = array(301 => "Moved Permanently",
302 => "Found",
# (or old)?
$this->log(LOG_INFO, 'claiming queue item = ' . $qi->notice_id);
$orig = clone($qi);
- $qi->claimed = DB_DataObject_Cast::dateTime();
+ $qi->claimed = common_sql_now();
$result = $qi->update($orig);
if ($result) {
$this->log(LOG_INFO, 'claim succeeded.');
# working around some weird DB_DataObject behaviour
$confirm->whereAdd(''); # clears where stuff
$original = clone($confirm);
- $confirm->claimed = DB_DataObject_Cast::dateTime();
+ $confirm->claimed = common_sql_now();
$result = $confirm->update($original);
if ($result) {
$this->log(LOG_INFO, 'Succeeded in claim! '. $result);