Jump to content

[fixed]ajax page search encoding issue


leoric
 Share

Recommended Posts

i used soma 's AJAX PAGE SEARCH module today

i found a issue after test:  when i type a keywords not use letter or number (chinese keywords) ,the result will return "Please enter a search term in the search box (upper right corner)...", obviously the search.php cant get inputbox "q"'s value..thise issue just happend on IE. Chrome and FireFox work ok.

then i open AjaxSearch.js,

find "data: param_name+"="+value," (line 76)  

replace into "data: param_name+"="+encodeURI(value),"

and its working..

nice module, thank you ,soma!

post-1860-0-04731000-1383631115_thumb.jp

  • Like 1
Link to comment
Share on other sites

add a question , 

this code not work( jquery version: 1.9)

        $('.ajaxSearch_close')
            .live('click',function(){
                $(this).closest('#ajaxSearch').fadeOut();
            });
you can use this replace it
    $(document).on("click", ".ajaxSearch_close", function (e) {
        $(this).closest('#ajaxSearch').fadeOut();
    });        
  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...