Commit d4bbe73a authored by Zosman's avatar Zosman
Browse files

Fixed margins

put the comments on the next line so the text isnt so wide
:zosman:
parent 87743515
//Zosman- This file was created in an effort to make /useradmin more usable.
//At the time this was created we had no searching feature of the users and it became somewhat hard to actually manage users
//This file has three js functions, one for each table in /useradmin , the functions allow a user to search through the table
function filterApplied() {
var input, filter, table, tr, td, i;
input = document.getElementById("appliedInput"); // the var that holdes input from text box
filter = input.value.toUpperCase(); //makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("appliedTable"); // the table at the moment this is called
tr = table.getElementsByTagName("tr"); //the table rows
for (i = 1; i < tr.length; i++) { // loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]); //sets td to the element, gets changed evrey loop itteration
input = document.getElementById("appliedInput");
// the var that holdes input from text box
filter = input.value.toUpperCase();
//makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("appliedTable");
// the table at the moment this is called
tr = table.getElementsByTagName("tr");
//the table rows
for (i = 1; i < tr.length; i++) {
// loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]);
//sets td to the element, gets changed evrey loop itteration
if (td) {
if (td.innerHTML.toUpperCase().indexOf(filter) > -1) {
tr[i].style.display = "";
......@@ -22,12 +29,18 @@ function filterApplied() {
function filterBlocked() {
var input, filter, table, tr, td, i;
input = document.getElementById("blockedInput"); // the var that holdes input from text box
filter = input.value.toUpperCase(); //makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("blockedTable"); // the table at the moment this is called
tr = table.getElementsByTagName("tr"); //the table rows
for (i = 1; i < tr.length; i++) { // loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]); //sets td to the element, gets changed evrey loop itteration
input = document.getElementById("blockedInput");
// the var that holdes input from text box
filter = input.value.toUpperCase();
//makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("blockedTable");
// the table at the moment this is called
tr = table.getElementsByTagName("tr");
//the table rows
for (i = 1; i < tr.length; i++) {
// loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]);
//sets td to the element, gets changed evrey loop itteration
if (td) {
if (td.innerHTML.toUpperCase().indexOf(filter) > -1) {
tr[i].style.display = "";
......@@ -41,12 +54,18 @@ function filterBlocked() {
function filterCurrent() {
var input, filter, table, tr, td, i;
input = document.getElementById("currentInput"); // the var that holdes input from text box
filter = input.value.toUpperCase(); //makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("currentTable"); // the table at the moment this is called
tr = table.getElementsByTagName("tr"); //the table rows
for (i = 1; i < tr.length; i++) { // loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]); //sets td to the element, gets changed evrey loop itteration
input = document.getElementById("currentInput");
// the var that holdes input from text box
filter = input.value.toUpperCase();
//makes the input all uppercase so we can eliminate that from the things can break stuff
table = document.getElementById("currentTable");
// the table at the moment this is called
tr = table.getElementsByTagName("tr");
//the table rows
for (i = 1; i < tr.length; i++) {
// loops through the table rows
td = (tr[i].getElementsByTagName("td")[1] || tr[i].getElementsByTagName("td")[2]);
//sets td to the element, gets changed evrey loop itteration
if (td) {
if (td.innerHTML.toUpperCase().indexOf(filter) > -1) {
tr[i].style.display = "";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment