Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #972268

    Dear Support Team
    Where can I set the sidebar for the search results page?
    Best regards

    #973264

    Hey Xinspirit,

    Thank you for using Enfold.

    The search results page uses the default sidebar or the “Displayed Everywhere” widget area. It’s in the Appearance > Widgets panel. Make sure that the Sidebar Settings > Sidebar on Pages option is turned on.

    Best regards,
    Ismael

    #1025146

    Is there a way to display a special “widget area” (aka sidebar) just for the search result page?

    The reason:
    I use the “Displayed Everywhere” widget area to display a search form.

    And therefor I have now twice a search form at the search results page:
    one in the sidebar and one on top of the search results.

    #1025418

    Hi,

    You can hide the other search bar with css. Would you like that?

    Best regards,
    Ismael

    #1025437

    Thanks, Ismael, I would like to have a sidebar only for the search results page, where I can put widgets in it, that appear nowhere else.
    So “Display Everywhere” is not the right way for me.

    #1025720

    Hi,

    You can modify the search.php template directly. Adjust the default get_sidebar function and point it to a sidebar with a custom name.

    
    get_sidebar('search-sidebar');
    

    You need to create a new template and name it sidebar-search-sidebar.php.

    // https://developer.wordpress.org/reference/functions/get_sidebar/

    Or install the Widget Logic plugin.

    // https://wordpress.org/plugins/widget-logic/

    Best regards,
    Ismael

    #1025921

    Thanks, Ismael, but I don’t understand what you mean with “new template”.

    Can I create a new “widget area” for the search results page and its widgets and … then what do I need to do next please?

    For example I created a new “widget area”, called “area_searchsidebar”, but when I add in search.php as you suggested

    get_sidebar('area_searchsidebar');

    … nothing happens, my custom sidebar is not shown.

    #1026230

    Hi,

    You need to create a new php file inside the child theme and name it according to the value of the get_sidebar function.

    get_sidebar('search-sidebar');
    

    The template file should be named.

    sidebar-search-sidebar.php.
    

    Have you tried using the Widget Logic plugin? That is much easier if you’re not familiar with templates.

    Best regards,
    Ismael

    #1026290

    thanks for your help, Ismael. I am not familiar with templates, never have understood “Widget Logic” plugin, but I found a similar one with more “visual” and for me easier to understand settings – “Widget Options“, and with that I got it easily to work by creating my desired widgets in the PAGE area and setting them via “Widget Options” to “Search”.

    #1026629

    Hi,

    That plugin seems very useful. Thanks for sharing. :)

    Best regards,
    Ismael

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.