From: Andrew Dolgov Date: Sun, 25 Jan 2009 06:09:46 +0000 (+0100) Subject: misc prefs ui updates X-Git-Tag: git2svn-syncpoint-master~21 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=eb70b7778181eedea1c287258ec76986fbd11c60;p=tt-rss.git misc prefs ui updates --- diff --git a/modules/pref-feeds.php b/modules/pref-feeds.php index e4738749..bcd79e74 100644 --- a/modules/pref-feeds.php +++ b/modules/pref-feeds.php @@ -1131,7 +1131,7 @@ if (ENABLE_FEED_BROWSER && !SINGLE_USER_MODE) { print " "; + onclick=\"javascript:browseFeeds()\" value=\"".__('More Feeds')."\">"; } $feeds_sort = db_escape_string($_GET["sort"]); diff --git a/modules/pref-users.php b/modules/pref-users.php index 08bc1082..386c428b 100644 --- a/modules/pref-users.php +++ b/modules/pref-users.php @@ -383,14 +383,8 @@ $sort = "login"; } - print "
-  "; - print "
"; if ($user_search) { diff --git a/prefs.js b/prefs.js index 813d8df6..5597dfdb 100644 --- a/prefs.js +++ b/prefs.js @@ -328,29 +328,32 @@ function addFeedCat() { link.value = ""; } - } + function addUser() { try { - var sqlexp = document.getElementById("uadd_box"); + var login = prompt(__("Please enter login:"), ""); - if (sqlexp.value.length == 0) { - alert(__("Can't add user: no login specified.")); - } else { - notify_progress("Adding user..."); - - var query = "backend.php?op=pref-users&subop=add&login=" + - param_escape(sqlexp.value); - - new Ajax.Request(query, { - onComplete: function(transport) { - userlist_callback2(transport); - } }); + if (login == null) { + return false; + } - sqlexp.value = ""; + if (login == "") { + alert(__("Can't create user: no login specified.")); + return false; } + + notify_progress("Adding user..."); + + var query = "backend.php?op=pref-users&subop=add&login=" + + param_escape(login); + + new Ajax.Request(query, { + onComplete: function(transport) { + userlist_callback2(transport); + } }); } catch (e) { exception_error("addUser", e);