Version: 3.7.x
This is mod rewrite of that: Live Search 1.0 (AJAX) - vBulletin.org Forum
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: http://mixplay.ru/
Live video: YouTube - Live Search
This is mod rewrite of that: Live Search 1.0 (AJAX) - vBulletin.org Forum
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:
HTML:
<form action="search.php?do=process" method="post">
<div id="tb-searchdiv">
<div id="tb-searchbox"><input type="text" id="search_input" name="query" tabindex="1001" maxlength="128" value="$vbphrase[search_forums]" onfocus="if(this.value=='$vbphrase[search_forums]')this.value='';" onblur="if(this.value=='$vbphrase[search_forums]')this.value='';" onkeyup="showHint(this.value)" /></div>
<input type="hidden" name="do" value="process" />
<input type="hidden" name="quicksearch" value="1" />
<input type="hidden" name="childforums" value="1" />
<input type="hidden" name="exactname" value="1" />
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
</div>
</form>
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:
HTML:
<div id="result_cont" class="alt2 tborder" style="width: 300px; height: 200px; position: absolute; top: 74px; right: 45px; z-index: 1000;">
and
HTML:
<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: http://mixplay.ru/
Live video: YouTube - Live Search