mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-15 09:55:56 +00:00
misc prefs ui updates
This commit is contained in:
@@ -1131,7 +1131,7 @@
|
|||||||
if (ENABLE_FEED_BROWSER && !SINGLE_USER_MODE) {
|
if (ENABLE_FEED_BROWSER && !SINGLE_USER_MODE) {
|
||||||
print " <input type=\"submit\" class=\"button\"
|
print " <input type=\"submit\" class=\"button\"
|
||||||
id=\"top25_feeds_btn\"
|
id=\"top25_feeds_btn\"
|
||||||
onclick=\"javascript:browseFeeds()\" value=\"".__('Other Feeds')."\">";
|
onclick=\"javascript:browseFeeds()\" value=\"".__('More Feeds')."\">";
|
||||||
}
|
}
|
||||||
|
|
||||||
$feeds_sort = db_escape_string($_GET["sort"]);
|
$feeds_sort = db_escape_string($_GET["sort"]);
|
||||||
|
|||||||
@@ -383,14 +383,8 @@
|
|||||||
$sort = "login";
|
$sort = "login";
|
||||||
}
|
}
|
||||||
|
|
||||||
print "<div class=\"prefGenericAddBox\">
|
|
||||||
<input id=\"uadd_box\"
|
|
||||||
onkeyup=\"toggleSubmitNotEmpty(this, 'user_add_btn')\"
|
|
||||||
onchange=\"toggleSubmitNotEmpty(this, 'user_add_btn')\"
|
|
||||||
size=\"15\"> ";
|
|
||||||
|
|
||||||
print "<input type=\"submit\" class=\"button\"
|
print "<input type=\"submit\" class=\"button\"
|
||||||
id=\"user_add_btn\" disabled=\"true\"
|
id=\"user_add_btn\"
|
||||||
onclick=\"javascript:addUser()\" value=\"".__('Create user')."\"></div>";
|
onclick=\"javascript:addUser()\" value=\"".__('Create user')."\"></div>";
|
||||||
|
|
||||||
if ($user_search) {
|
if ($user_search) {
|
||||||
|
|||||||
21
prefs.js
21
prefs.js
@@ -328,30 +328,33 @@ function addFeedCat() {
|
|||||||
link.value = "";
|
link.value = "";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function addUser() {
|
function addUser() {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
var sqlexp = document.getElementById("uadd_box");
|
var login = prompt(__("Please enter login:"), "");
|
||||||
|
|
||||||
|
if (login == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (login == "") {
|
||||||
|
alert(__("Can't create user: no login specified."));
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (sqlexp.value.length == 0) {
|
|
||||||
alert(__("Can't add user: no login specified."));
|
|
||||||
} else {
|
|
||||||
notify_progress("Adding user...");
|
notify_progress("Adding user...");
|
||||||
|
|
||||||
var query = "backend.php?op=pref-users&subop=add&login=" +
|
var query = "backend.php?op=pref-users&subop=add&login=" +
|
||||||
param_escape(sqlexp.value);
|
param_escape(login);
|
||||||
|
|
||||||
new Ajax.Request(query, {
|
new Ajax.Request(query, {
|
||||||
onComplete: function(transport) {
|
onComplete: function(transport) {
|
||||||
userlist_callback2(transport);
|
userlist_callback2(transport);
|
||||||
} });
|
} });
|
||||||
|
|
||||||
sqlexp.value = "";
|
|
||||||
}
|
|
||||||
|
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
exception_error("addUser", e);
|
exception_error("addUser", e);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user