From: Andrew Dolgov Date: Tue, 2 Apr 2013 10:36:00 +0000 (+0400) Subject: remove obsolete checkDate stuff X-Git-Tag: 1.7.6~29 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=8956b3a607be2d0a28704713d6a5d915e6c82fd3;p=tt-rss.git remove obsolete checkDate stuff --- diff --git a/classes/rpc.php b/classes/rpc.php index f0218f91..64e09d1e 100644 --- a/classes/rpc.php +++ b/classes/rpc.php @@ -480,14 +480,6 @@ class RPC extends Handler_Protected { print json_encode($articles); } - function checkDate() { - $date = db_escape_string($this->link, $_REQUEST["date"]); - $date_parsed = strtotime($date); - - print json_encode(array("result" => (bool)$date_parsed, - "date" => date("c", $date_parsed))); - } - function assigntolabel() { return $this->labelops(true); } diff --git a/js/functions.js b/js/functions.js index 0b39cc46..56074259 100644 --- a/js/functions.js +++ b/js/functions.js @@ -548,28 +548,6 @@ function fatalError(code, msg, ext_info) { } } -/* function filterDlgCheckType(sender) { - - try { - - var ftype = sender.value; - - // if selected filter type is 5 (Date) enable the modifier dropbox - if (ftype == 5) { - Element.show("filterDlg_dateModBox"); - Element.show("filterDlg_dateChkBox"); - } else { - Element.hide("filterDlg_dateModBox"); - Element.hide("filterDlg_dateChkBox"); - - } - - } catch (e) { - exception_error("filterDlgCheckType", e); - } - -} */ - function filterDlgCheckAction(sender) { try { @@ -603,34 +581,6 @@ function filterDlgCheckAction(sender) { } -function filterDlgCheckDate() { - try { - var dialog = dijit.byId("filterEditDlg"); - - var reg_exp = dialog.attr('value').reg_exp; - - var query = "?op=rpc&method=checkDate&date=" + reg_exp; - - new Ajax.Request("backend.php", { - parameters: query, - onComplete: function(transport) { - - var reply = JSON.parse(transport.responseText); - - if (reply['result'] == true) { - alert(__("Date syntax appears to be correct:") + " " + reply['date']); - return; - } else { - alert(__("Date syntax is incorrect.")); - } - - } }); - - - } catch (e) { - exception_error("filterDlgCheckDate", e); - } -} function explainError(code) { return displayDlg(__("Error explained"), "explainError", code);