diff options
author | Andrew Dolgov <[email protected]> | 2017-12-01 23:49:14 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2017-12-01 23:49:14 +0300 |
commit | fbe7cb0a4802519c405c86394a8426791d48fe26 (patch) | |
tree | da9c3b89828b8eecb0a273acaac2c973dbe814ee /js/functions.js | |
parent | 9652fa6b6687b0aa2ac55cd735cdf43f32398faa (diff) |
rpc: switch to PDO
Diffstat (limited to 'js/functions.js')
-rwxr-xr-x | js/functions.js | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/js/functions.js b/js/functions.js index aff20a33c..d52fee894 100755 --- a/js/functions.js +++ b/js/functions.js @@ -1200,31 +1200,6 @@ function backend_sanity_check_callback(transport) { } -function quickAddCat(elem) { - var cat = prompt(__("Please enter category title:")); - - if (cat) { - - var query = "?op=rpc&method=quickAddCat&cat=" + param_escape(cat); - - notify_progress("Loading, please wait...", true); - - new Ajax.Request("backend.php", { - parameters: query, - onComplete: function (transport) { - var response = transport.responseXML; - var select = response.getElementsByTagName("select")[0]; - var options = select.getElementsByTagName("option"); - - dropbox_replace_options(elem, options); - - notify(''); - - } }); - - } -} - function genUrlChangeKey(feed, is_cat) { var ok = confirm(__("Generate new syndication address for this feed?")); @@ -1263,34 +1238,6 @@ function genUrlChangeKey(feed, is_cat) { return false; } -function dropbox_replace_options(elem, options) { - while (elem.hasChildNodes()) - elem.removeChild(elem.firstChild); - - var sel_idx = -1; - - for (var i = 0; i < options.length; i++) { - var text = options[i].firstChild.nodeValue; - var value = options[i].getAttribute("value"); - - if (value == undefined) value = text; - - var issel = options[i].getAttribute("selected") == "1"; - - var option = new Option(text, value, issel); - - if (options[i].getAttribute("disabled")) - option.setAttribute("disabled", true); - - elem.insert(option); - - if (issel) sel_idx = i; - } - - // Chrome doesn't seem to just select stuff when you pass new Option(x, y, true) - if (sel_idx >= 0) elem.selectedIndex = sel_idx; -} - // mode = all, none, invert function selectTableRows(id, mode) { var rows = $(id).rows; |