View vars will now search properly. Meaning it will only search from what is displayed. IE: if you type it name, it will only search for displayed text containing 'name' and not for the <a name='...'> things.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2322 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
baloh.matevz
2011-10-03 03:57:11 +00:00
parent 577ec5eba9
commit 1706e00d3b

View File

@@ -32,6 +32,7 @@ client
title = "[D] (\ref[D]) = [D.type]"
body += {"<script type="text/javascript">
function updateSearch(){
var filter_text = document.getElementById('filter');
var filter = filter_text.value.toLowerCase();
@@ -113,7 +114,7 @@ client
{
try{
var li = lis\[i\];
if ( li.innerHTML.toLowerCase().indexOf(filter) == -1 )
if ( li.innerText.toLowerCase().indexOf(filter) == -1 )
{
vars_ol.removeChild(li);
i--;