cancel
Showing results for 
Search instead for 
Did you mean: 

Change the layout of the Search Page

SOLVED

Change the layout of the Search Page

I would like to change the search page to products first and then the following in priority categories and then blogs etc  Thank you in advanceSearch Page ResultsSearch Page Results

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Change the layout of the Search Page

Trying one of their demos, it looks like the order is the one you're looking for: 

 

http://themes.magesolution.com/supro/de//instantsearch/result/?q=test

--- Code lover, nature addicted ---

View solution in original post

8 REPLIES 8

Re: Change the layout of the Search Page

Hi @gloria_ lozinsk,

In your custom theme create/update the catalogsearch_result_index.xml in following path: app/design/frontend/<Vendor>/<your_theme>/Magento_CatalogSearch/layout/catalogsearch_result_index.xml

Then you can change your block as per your requirement.

For more info:
https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/xml-manage.html


I hope it will help you!

Re: Change the layout of the Search Page

Sorry but here is what I currently have..cannot find the Magento_CatalogSearch/layout/catalogsearch_result_index.xml

search page.png

thank you for your assistance.

Sincerely,

Gloria

 

 

 

Re: Change the layout of the Search Page

any other suggestions

Thank you in advance

Sincerely,

Gloria

Re: Change the layout of the Search Page

Hi @gloria_ lozinsk 

May be this file is not overridden in your theme. 

You can find at below location.

vendor/magento/module-catalog-search/view/frontend/layout/catalogsearch_result_index.xml

You can override this file to your theme.
https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/layout-override.html

I hope it will help you!

Re: Change the layout of the Search Page

I am sorry but I do not see how to rearrange in this document

<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<attribute name="class" value="page-products"/>
<referenceContainer name="content">
<block class="Magento\CatalogSearch\Block\Result" name="search.result" template="Magento_CatalogSearch::result.phtml">
<block class="Magento\CatalogSearch\Block\SearchResult\ListProduct" name="search_result_list" template="Magento_Catalog:Smiley Tongueroduct/list.phtml">
<arguments>
<!-- If argument's position depends on image size changeable in VDE:
positions:list-secondary,grid-secondary,list-actions,grid-actions,list-primary,grid-primary
-->
<argument name="positioned" xsi:type="string">positions:list-secondary</argument>
</arguments>
<block class="Magento\Catalog\Block\Product\ProductList\Toolbar" name="product_list_toolbar" template="Magento_Catalog:Smiley Tongueroduct/list/toolbar.phtml">
<block class="Magento\Theme\Block\Html\Pager" name="product_list_toolbar_pager"/>
</block>
<action method="setToolbarBlockName">
<argument name="name" xsi:type="string">product_list_toolbar</argument>
</action>
<block class="Magento\Framework\View\Element\RendererList" name="category.product.type.details.renderers" as="details.renderers">
<block class="Magento\Framework\View\Element\Template" name="category.product.type.details.renderers.default" as="default"/>
</block>
<block class="Magento\Catalog\Block\Product\ProductList\Item\Container" name="catalogsearch.product.addto" as="addto">
<block class="Magento\Catalog\Block\Product\ProductList\Item\AddTo\Compare"
name="catalogsearch.product.addto.compare" as="compare"
template="Magento_Catalog:Smiley Tongueroduct/list/addto/compare.phtml"/>
</block>
</block>
<action method="setListOrders"/>
<action method="setListModes"/>
<action method="setListCollection"/>
</block>
<block class="Magento\Framework\View\Element\Template" name="search.search_terms_log" template="Magento_CatalogSearch::search_terms_log.phtml">
<arguments>
<argument name="search_terms_log" xsi:type="object">Magento\CatalogSearch\Block\SearchTermsLog</argument>
</arguments>
</block>
</referenceContainer>
</body>
</page>

Thank you in advance

Re: Change the layout of the Search Page

Hi @gloria_ lozinsk

 

did you already investigated in theme settings or asked to theme support if there is any customization on that page?

 

Did you take a look to the theme app/code/... folders? (if any)

--- Code lover, nature addicted ---

Re: Change the layout of the Search Page

Trying one of their demos, it looks like the order is the one you're looking for: 

 

http://themes.magesolution.com/supro/de//instantsearch/result/?q=test

--- Code lover, nature addicted ---

Re: Change the layout of the Search Page

Its worked in my case.