rejetto forum
Software => HTML & templates => HFS ~ HTTP File Server => RAWR-Designs => Topic started by: Stonesteel on October 07, 2013, 02:01:52 AM
-
Greetings!
I just wanted to ask, what value should I change in these codes so that the default search is File(s) only not Both, because the default option selected in the template is Both.
function searchQuery() {
frm = document.searchForm;
if(frm.query.value.length < 3) {
alert(lv_searchAlert);
} else {
frm.recursive.checked ? recursive ="&recursive" : recursive ="";
for(x=0; x<frm.choice.length; x++) {
if(frm.choice[x].checked ==1) {
if(frm.choice[x].value =="file") {
searchMode ="?files-filter=";
filter="&folders-filter=%5C";
} else if(frm.choice[x].value =="folder") {
searchMode ="?folders-filter=";
filter="&files-filter=%5C";
} else {
searchMode ="?filter=";
filter="";
}
}
}
for(c=0; c<frm.root.length; c++) {
if(frm.root[c].checked ==1) {
frm.root[c].value =="current" ? searchFrom ="http://"+serverHost+serverFolder : searchFrom ="http://"+serverHost;
}
}
document.location.href = searchFrom+searchMode+"*"+frm.query.value+"*"+recursive+filter;
}
}
-
It's not in the default template????
version of hfs and what is the template used?
-
Hi Mars, I got it from the default template/rawr_default/code/rawr_main.js
it's inside the javascript..
I am currently using HFS 282, with the latest template 0.1.3. ;D
-
Any update here? ;D
-
the "default" it's not in the code you posted.
you posted the javascript, while it's actually in the html.
-
Hello rejetto, but I found the code inside the rawr_main javascript, well then what should I change in the code so that the default search will be in the File(s) option not in Both?
-
i cannot search it myself, sorry