Open new page results

This topic contains 7 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 2 years, 10 months ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #33473
    hunscuzzy63
    hunscuzzy63
    Participant

    Hello,
    I don’t understand how I can display results in another page.
    I try to set up the navbar search input to open the search page and display the results.
    But, it doesn’t seems to works.
    It’s a custom theme and the search form that I’m trying to use is called “Navbar”.
    Can you help me to do it? I tried a lot of things that I found on your documentation.
    Thanks

    #33480
    hunscuzzy63
    hunscuzzy63
    Participant

    Hi,
    If needed, I also can send you the FTP access.

    #33482
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi,

    Make sure to set the magnifier and the return button events to redirect to the results page.
    Please note, that the plugin can not create custom results pages, it is completely controlled by the the theme you are using – that needs to be customized there.
    Once the plugin redirects to the results page, you can enable the results page override feature – so instead of the core wordpress search results, the one from this plugin are displayed instead.

    Best,
    Ernest Marcinko

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


    #33484
    hunscuzzy63
    hunscuzzy63
    Participant

    Hi Ernest,
    Well, can you please send me more informatin about the custom results pages please?
    It’s a custom theme, made by myself but I don’t know anything about the results page so a little bit of documentation is really welcome!

    #33488
    hunscuzzy63
    hunscuzzy63
    Participant

    Ernest,
    I tried to look at this more in details but I don’t find your answer really usefull…
    Can you give me an example of a code that should works or just take a look at mine or anything else?
    Because with this informations, I can’t go ahead.
    Thanks!

    #33489
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Well I am not a theme developer, so I am not familiar with the all of the details, but as far as I know the search.php theme file should be handling the search results.
    I would probably start by taking a look at a sample theme, which has an implemented search.php file, and go from there. There should be a basic posts loop there for sure to handle the results, that I know. Unfortuantely I am no expert with theme development and inner workings.

    Best,
    Ernest Marcinko

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


    #33491
    hunscuzzy63
    hunscuzzy63
    Participant

    I don’t understand something: Why do your plugin require native search feature?
    I mean, it’s not the same form, so not the same way to display results, no?

    Also, the Wp documentation is not really dev friendly.
    I don’t find a way to display wordpress results on custom page.

    Is there another way to display results form a search input made with your plugin?

    Thanks

    #33497
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    The way wordpress works is the reason why the native search results handling is required for the results page. The results page handler is the core wordpress feature where the search results are handled, so the search plugins know where to initiate the search override functions.
    For a simpler solution, you can try using Elementor to add a posts archive widget to the results page, but coding it might be just as simple.

    The coding should not be any difficult either, all themes come with a results page handler. You can take a sample from the core wordpress themes, the search.php file usually contains the header, footer, the body part, and a simple posts loop:

    while ( have_posts() ) : the_post();
    
    	/**
    	 * Run the loop for the search to output the results.
    	 * If you want to overload this in a child theme then include a file
    	 * called content-search.php and that will be used instead.
    	 */
    	get_template_part( 'template-parts/content', 'search' );
    
    // End the loop.
    endwhile;
    Best,
    Ernest Marcinko

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


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

You must be logged in to reply to this topic.