Possible Ajax Conflict

This topic contains 4 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 1 month, 1 week ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #46646
    tomo_5
    tomo_5
    Participant

    Page url: http://dev.buildreview.org/?s=test123&asp_active=1&p_asid=2&p_asp_data=1&filters_initial=1&filters_changed=0&qtranslate_lang=0&woo_currency=NZD&current_page_id=35607
    Search String: test123
    Search via Sidebar search box
    Expected search results: 12 Posts
    Theme displays 10 archive posts then load more button
    Pressing load more button fails to load remaining 2 posts
    Load More Button is ajax

    This is a development website, feel free to modify data and seetings to suit your needs.
    If you need directory access then feel free to download directory plugin.
    Any problems, please email: [email protected]

    I am also curious why the search results url is so long, is there a way to tidy this up please?

    Many thanks,

    Ian

    #46655
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi Ian,

    I only suggest using a load-more feature if it respects the current query string (the arguments in the browser URL). They usually do that, but not in every case, sometimes the load-more will try to load the next page without the query arguments, which may not trigger the search override. In worst cases they use a custom query via the ajax handler, in which case it’s not possible to override.

    I have tried to enable that, and it is unfortunately using a custom search endpoint to load more results, not actually loading the next results page. It is not a bad practice, but it makes it nearly impossible to override as it is not recognized as a search query.

    I suggest using regular pagination, it is usually much better in every aspec, as it does not require extra scripts and it is SEO and navigation friendly as well.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #46661
    tomo_5
    tomo_5
    Participant
    You cannot access this content.
    #46663
    tomo_5
    tomo_5
    Participant

    Also, should the theme’s existing full site search be able to use the live ajax search? Our search bar in the header may need checking please.

    #46672
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    I also notice on the theme that they have embeded the SearchWP Live Ajax Search plugin into the theme, maybe this is also causing possible problems?

    Could be but unlikely. It is rather that the “load more” request is not an actual search query to the results page, but a custom made query to a custom handler somewhere on the server.

    site search be able to use the live ajax search?
    Very likely. First I would suggest trying the automatic replacement feature. If the search form is printed via the get_search_form() call, then it should be replaced automatically.
    If no luck, then checking the theme customizer/editor might be the way. Most themes offer replacing the widget in the pop-up with anything, and there you could use the Ajax Search Pro shortcode.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.