This is mod rewrite of that:
Version 1.3
I'm added few functions:
Upload all files from folder "upload" in root directory of your forum.
Import product
If you use vbadvanced, open vbulletin_ajax_live_search.js and add your forum path in var hurl="", like var hurl="http://your_site.com/forum/"
If you dont have opened search field, add this code where you prefer:
If you already have this form, find <input type="text" ... /> and after type="text" add id="search_input" onkeyup="showHint(this.value)"
Tuning:
For change position window and him style open template lsearch.
Edit this string:
and
right: 74px // indentation from the right edge of the screen (left from left), set in px or in %
top: 45px // indentation from the top edge of the screen (bottom from bottom), set in px or in %
width: 300px // width of window, set in px or in %
height: 200px // height of window, set in px or in %
If you want change background color of window, replace alt2 with alt1, or remove alt2 and left of width add background-color: #XXXXXX, were XXXXXX - code your color.
Live DEMO:
Live video:
You must be registered for see links
Version 1.3
I'm added few functions:
- search only, if typed >= 3 symbols;
- header to window with button close;
- message about no result;
- limit number of threads;
- highlight words in result
- trim title of thread, if it large
Upload all files from folder "upload" in root directory of your forum.
Import product
If you use vbadvanced, open vbulletin_ajax_live_search.js and add your forum path in var hurl="", like var hurl="http://your_site.com/forum/"
If you dont have opened search field, add this code where you prefer:
Mã:
[COLOR=#ff8000]<form action=[COLOR=#0000ff]"search.php?do=process"[/COLOR] method=[COLOR=#0000ff]"post"[/COLOR]>[/COLOR]
[COLOR=#000080]<div id=[COLOR=#0000ff]"tb-searchdiv"[/COLOR]>[/COLOR]
[COLOR=#000080]<div id=[COLOR=#0000ff]"tb-searchbox"[/COLOR]>[/COLOR][COLOR=#ff8000]<input type=[COLOR=#0000ff]"text"[/COLOR] id=[COLOR=#0000ff]"search_input"[/COLOR] name=[COLOR=#0000ff]"query"[/COLOR] tabindex=[COLOR=#0000ff]"1001"[/COLOR] maxlength=[COLOR=#0000ff]"128"[/COLOR] value=[COLOR=#0000ff]"$vbphrase[live_search]"[/COLOR] onfocus=[COLOR=#0000ff]"if(this.value=='$vbphrase[live_search]')this.value='';"[/COLOR] onblur=[COLOR=#0000ff]"if(this.value=='$vbphrase[live_search]')this.value='';"[/COLOR] onkeyup=[COLOR=#0000ff]"showHint(this.value)"[/COLOR] />[/COLOR][COLOR=#000080]</div>[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"do"[/COLOR] value=[COLOR=#0000ff]"process"[/COLOR] />[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"quicksearch"[/COLOR] value=[COLOR=#0000ff]"1"[/COLOR] />[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"childforums"[/COLOR] value=[COLOR=#0000ff]"1"[/COLOR] />[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"exactname"[/COLOR] value=[COLOR=#0000ff]"1"[/COLOR] />[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"s"[/COLOR] value=[COLOR=#0000ff]"$session[sessionhash]"[/COLOR] />[/COLOR]
[COLOR=#ff8000]<input type=[COLOR=#0000ff]"hidden"[/COLOR] name=[COLOR=#0000ff]"securitytoken"[/COLOR] value=[COLOR=#0000ff]"$bbuserinfo[securitytoken]"[/COLOR] />[/COLOR]
[COLOR=#000080]</div>[/COLOR]
[COLOR=#ff8000]</form>[/COLOR]
If you already have this form, find <input type="text" ... /> and after type="text" add id="search_input" onkeyup="showHint(this.value)"
Tuning:
For change position window and him style open template lsearch.
Edit this string:
PHP:
<div id="result_cont" class="alt2 tborder" style="width: 300px; height: 200px; position: absolute; top: 74px; right: 45px; z-index: 1000;">
and
PHP:
<div style="padding: $stylevar[cellpadding]px; height: 200px; overflow: auto;" id="search_results">
right: 74px // indentation from the right edge of the screen (left from left), set in px or in %
top: 45px // indentation from the top edge of the screen (bottom from bottom), set in px or in %
width: 300px // width of window, set in px or in %
height: 200px // height of window, set in px or in %
If you want change background color of window, replace alt2 with alt1, or remove alt2 and left of width add background-color: #XXXXXX, were XXXXXX - code your color.
Live DEMO:
You must be registered for see links
Live video:
You must be registered for see links
You must be registered for see links