Commit b706fb82 authored by Zosman's avatar Zosman
Browse files

changed names of the id for table and input box

parent bc69b6bd
Pipeline #827 passed with stage
in 1 minute and 12 seconds
...@@ -33,9 +33,9 @@ SRCT Go • Administration Panel ...@@ -33,9 +33,9 @@ SRCT Go • Administration Panel
<form method="post" action="useradmin"> <form method="post" action="useradmin">
<!-- csrf protection --> <!-- csrf protection -->
{% csrf_token %} {% csrf_token %}
<input type="text" id="myInput" onkeyup="myFunction()" placeholder="Search for Full names.."> <input type="text" id="appliedInput" onkeyup="filterApplied()" placeholder="Search for Full names..">
<!-- define out table of users that need approval --> <!-- define out table of users that need approval -->
<table class="table table-striped table-hover" id="myTable"> <table class="table table-striped table-hover" id="appliedTable">
<!-- define the header row --> <!-- define the header row -->
<thead> <thead>
<tr> <tr>
......
function myFunction() { function filterApplied() {
var input, filter, table, tr, td, i; var input, filter, table, tr, td, i;
input = document.getElementById("myInput"); // the var that holdes input from text box input = document.getElementById("appliedInput"); // the var that holdes input from text box
filter = input.value.toUpperCase(); //makes the input all uppercase for some fucking reason filter = input.value.toUpperCase(); //makes the input all uppercase for some fucking reason
table = document.getElementById("myTable"); // the table at the moment this is called table = document.getElementById("appliedTable"); // the table at the moment this is called
tr = table.getElementsByTagName("tr"); //the table rows tr = table.getElementsByTagName("tr"); //the table rows
for (i = 1; i < tr.length; i++) { // loops through the table rows for (i = 1; i < tr.length; i++) { // loops through the table rows
td = tr[i].getElementsByTagName("td")[2]; //sets td to the element, gets changed evrey loop itteration td = tr[i].getElementsByTagName("td")[2]; //sets td to the element, gets changed evrey loop itteration
......
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