anchor.diff:  		if (authenticated)
   			switch(screen)
   				if(1.0)
  +
  +					//body tag start + onload and onkeypress (onkeyup) javascript event calls
  +					dat += "<body onload='selectTextField(); updateSearch();' onkeyup='updateSearch();'>"
  +					//search bar javascript
  +					dat += {"
  +
  +		<head>
  +			<script src="libraries.min.js"></script>
  +			<script type='text/javascript'>
  +
  +				function updateSearch(){
  +					var filter_text = document.getElementById('filter');
  +					var filter = filter_text.value.toLowerCase();
  +
  +					if(complete_list != null && complete_list != ""){
  +						var mtbl = document.getElementById("maintable_data_archive");
  +						mtbl.innerHTML = complete_list;
  +					}
  +
  +					if(filter.value == ""){
  +						return;
  +					}else{
  +						$("#maintable_data").children("tbody").children("tr").children("td").children("input").filter(function(index)
  +						{
  +							return $(this)\[0\].value.toLowerCase().indexOf(filter) == -1
  +						}).parent("td").parent("tr").hide()
  +					}
  +				}
  +
  +				function selectTextField(){
  +					var filter_text = document.getElementById('filter');
  +					filter_text.focus();
  +					filter_text.select();
  +				}
  +
  +			</script>
  +		</head>
  +
  +
  +	"}
   					dat += {"
   <p style='text-align:center;'>"}
  -					dat += text("<A href='?src=\ref[];choice=Search Records'>Search Records</A><BR>", src)
   					dat += text("<A href='?src=\ref[];choice=New Record (General)'>New Record</A><BR>", src)
  +					//search bar
  +					dat += {"
  +						<table width='560' align='center' cellspacing='0' cellpadding='5' id='maintable'>
  +							<tr id='search_tr'>
  +								<td align='center'>
  +									<b>Search:</b> <input type='text' id='filter' value='' style='width:300px;'>
  +								</td>
  +							</tr>
  +						</table>
  +					"}
   					dat += {"
   </p>
   <table style="text-align:center;" cellspacing="0" width="100%">
  
positive.code: 						dat += "<B>Security Record Lost!</B><BR>"
  						dat += text("<A href='?src=\ref[];choice=New Record (Security)'>New Security Record</A><BR><BR>", src)
  					dat += text("\n<A href='?src=\ref[];choice=Delete Record (ALL)'>Delete Record (ALL)</A><BR><BR>\n<A href='?src=\ref[];choice=Print Record'>Print Record</A><BR>\n<A href='?src=\ref[];choice=Return'>Back</A><BR>", src, src, src)
  				if(4.0)
  					if(!Perp.len)
  						dat += text("ERROR.  String could not be located.<br><br><A href='?src=\ref[];choice=Return'>Back</A>", src)
  					else
  						dat += {"
  <table style="text-align:center;" cellspacing="0" width="100%">
  <tr>					"}
  						dat += text("<th>Search Results for '[]':</th>", tempname)
  						dat += {"
  </tr>
  </table>
  <table style="text-align:center;" border="1" cellspacing="0" width="100%">
  <tr>
  <th>Name</th>
  <th>ID</th>
  <th>Rank</th>
  <th>Fingerprints</th>
  <th>Criminal Status</th>
  </tr>					"}
  						for(var/i=1, i<=Perp.len, i += 2)
  							var/crimstat = ""
  							var/datum/data/record/R = Perp[i]
  							if(istype(Perp[i+1],/datum/data/record/))
  								var/datum/data/record/E = Perp[i+1]
  								crimstat = E.fields["criminal"]
  							var/background
  							switch(crimstat)
  								if("*Arrest*")
  									background = "'background-color:#DC143C;'"
  								if("Incarcerated")
  									background = "'background-color:#CD853F;'"
  								if("Parolled")
  									background = "'background-color:#CD853F;'"
  								if("Released")
  									background = "'background-color:#3BB9FF;'"
  								if("None")
  									background = "'background-color:#00FF7F;'"
  								if("")
  									background = "'background-color:#FFFFFF;'"
  									crimstat = "No Record."
  							dat += text("<tr style=[]><td><A href='?src=\ref[];choice=Browse Record;d_rec=\ref[]'>[]</a></td>", background, src, R, R.fields["name"])
  							dat += text("<td>[]</td>", R.fields["id"])
  							dat += text("<td>[]</td>", R.fields["rank"])
  							dat += text("<td>[]</td>", R.fields["fingerprint"])
  							dat += text("<td>[]</td></tr>", crimstat)
  						dat += "</table><hr width='75%' />"
  						dat += text("<br><A href='?src=\ref[];choice=Return'>Return to index.</A>", src)
  				else
  		else
  			dat += text("<A href='?src=\ref[];choice=Log In'>{Log In}</A>", src)
  
negative.code: <th>Records:</th>
  </tr>
  </table>
  
  <span id='maintable_data_archive'>
  <table id='maintable_data' style="text-align:center;" border="1" cellspacing="0" width="100%">
  <tr>
  <th><A href='?src=\ref[src];choice=Sorting;sort=name'>Name</A></th>
  <th><A href='?src=\ref[src];choice=Sorting;sort=id'>ID</A></th>
  