vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Add-On Releases - [AJAX] Live Search (https://vborg.vbsupport.ru/showthread.php?t=189970)

CraiovaOnLine 10-23-2008 08:02 PM

super mode
10x mate
just one question ...can i set it up to search just within one forum or just within one category ?
10x again

iglobal 10-24-2008 04:50 AM

Quote:

Originally Posted by Gasper (Post 1648709)
You must change UTF-8 to Latin1 ;)

Where should I change that?

mad@Max 10-24-2008 06:51 AM

CraiovaOnLine, Yes, add after
PHP Code:

". TABLE_PREFIX ."thread.forumid NOT IN (0 $excludelist

this
PHP Code:

". TABLE_PREFIX ."thread.forumid IN (1,2,3,4,5,...) 

iglobal, above
PHP Code:

$query addslashes(trim($_GET['query'])); 

add
PHP Code:

$query iconv('UTF-8'$stylevar['charset'], $query); 


b6gm6n 10-24-2008 10:19 AM

more instructions please, not so clear... it's for forms, not for my default search, uninstalled as not needed, thanks

PoetJA-1975 10-30-2008 08:02 AM

The following is the contents of the vbulletin_live_ajax_search.js file:

Code:

/**
 * Live Search v1.2
 * @author mad@Max
 */
var xmlHttp3
function showHint(word)
{
document.getElementById("search_results").innerHTML = '<p></p><p></p><p align="center" class="smallfont"><img src="images/misc/progress.gif" /> Searching...</p>';
        xmlHttp3=GetXmlHttpObject3()
        if (xmlHttp3==null)
        {
                alert ("Browser does not support HTTP Request")
                return
        }
        var url=hurl+"ajax_search.php"
        url=url+"?query="+word
        xmlHttp3.onreadystatechange=stateChanged3
        xmlHttp3.open("GET",url,true)
        xmlHttp3.send(null)
}

function stateChanged3()
{
        var sSearch = document.getElementById("search_input").value;
        var obj = document.getElementById("search_results");
        var obj2 = document.getElementById("q_search");
        if (sSearch.length>=3){
        if (xmlHttp3.readyState==4 || xmlHttp3.readyState=="complete")
        {
                obj2.style.display = 'block';
                obj.innerHTML=xmlHttp3.responseText;
        }
        } else {
                obj2.style.display = 'none';
                obj.innerHTML = '';
        }
}

function GetXmlHttpObject3()
{
        var objXMLHttp3=null
        if (window.XMLHttpRequest)
        {
                objXMLHttp3=new XMLHttpRequest()
        }
        else if (window.ActiveXObject)
        {
                objXMLHttp3=new ActiveXObject("Microsoft.XMLHTTP")
        }
        return objXMLHttp3
}

As per the instructions - where do you add your forum path in var hurl="" -- I do not see that bit of code in the .js file

Thanx,

Jacquii.

ForumsMods 10-30-2008 07:07 PM

Here:
Code:

/**
 * Live Search v1.2
 * @author mad@Max
 */
var xmlHttp3
function showHint(word)
{
document.getElementById("search_results").innerHTML = '<p></p><p></p><p align="center" class="smallfont"><img src="images/misc/progress.gif" /> Searching...</p>';
    xmlHttp3=GetXmlHttpObject3()
    if (xmlHttp3==null)
    {
        alert ("Browser does not support HTTP Request")
        return
    }
    var url=hurl+"ajax_search.php"
    url=url+"?query="+word
    xmlHttp3.onreadystatechange=stateChanged3
    xmlHttp3.open("GET",url,true)
    xmlHttp3.send(null)
}

function stateChanged3()
{
    var sSearch = document.getElementById("search_input").value;
    var obj = document.getElementById("search_results");
    var obj2 = document.getElementById("q_search");
    if (sSearch.length>=3){
    if (xmlHttp3.readyState==4 || xmlHttp3.readyState=="complete")
    {
        obj2.style.display = 'block';
        obj.innerHTML=xmlHttp3.responseText;
    }
    } else {
        obj2.style.display = 'none';
        obj.innerHTML = '';
    }
}

function GetXmlHttpObject3()
{
    var objXMLHttp3=null
    if (window.XMLHttpRequest)
    {
        objXMLHttp3=new XMLHttpRequest()
    }
    else if (window.ActiveXObject)
    {
        objXMLHttp3=new ActiveXObject("Microsoft.XMLHTTP")
    }
    return objXMLHttp3
}


Quantnet 11-01-2008 08:32 PM

it seems that the search function works well under the site.com/forum/ but when you move to a different place like site.com/wiki/ and do a search from there, it will return error.

I tried to search in the top level domain site.com/ and it returns something like this

http://www.site.com/ 67.86.193.xxx /ajax_search.php?query=and www.site.com Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3 (.NET CLR 3.5.30729) 404 Please contact admin if you can not find the content you are looking for.

This should be easy by using relative path instead of absolute path?

PoetJA-1975 11-01-2008 11:12 PM

Hi MAXIM :)

Actually- I have the 1st version installed at http://JPiCForum.info - it works just fine with vBSEO installed - I've installed the current version on http://DiscussWLS.com - and the it does not work with vBSEO installed. Not only that - but I could not find the edit to make it work on the vBadvanced page. You probably need to clarify the instructions in the download folder.

So my question - Can you make the 1st version upload available for download again please?

Thanx,

Jacquii.

mad@Max 11-01-2008 11:14 PM

OMG. Use lasted version of mod also files.

Quantnet 11-01-2008 11:49 PM

you can find ver 1.2 a few page back. Someone posted it there.


All times are GMT. The time now is 01:04 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01493 seconds
  • Memory Usage 1,755KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (4)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete