I have 3 modules overridden from


Catalog and


In my 4th module, i just need to render the products after hitting the below URL(page shows blank) which is rendering from the 1st 3 modules properly.




route id="merchandisingpage" frontName="merchandisingpage"


//Have given the preference type for all the modules overridden in 1st 3 modules.
//Need clarification as this can be done!

4th module Vendor\Module\Controller\Result\Index.php

class Index extends \Magento\Framework\App\Action\Action
   public function execute()
      $query = $this->request->getParam('q');   
    $q = $this->request; 
    $re =  array();
    $re = $q->getParams();   

    $re['filters'] = true;
    $re['q'] = $re['product'];  
    $payload = $re;  


<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="3columns" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <action method="setTitle">
        <argument name="title" xsi:type="string">Merchandising</argument>
    <referenceBlock name="search.result">
      <action method="setTemplate">
            <argument name="template" xsi:type="string">Vendor_Module1::result.phtml</argument>
    <referenceBlock class=" before="-" name="catalogsearch.leftnav">
      <action method="setTemplate">
            <argument name="template" xsi:type="string">Vendor_Module2::layer/view.phtml</argument>
    <referenceBlock class=" name="product_list_toolbar" >
      <action method="setTemplate">
        <argument name="template" xsi:type="string">Vendor_Module3::product/list/toolbar.phtml</argument>

I need to get the products rendered in frontpage.

I get blank screen, without errors or exception.

1 Answer 1


You need to recompile the Magento project::

sudo php /[your project dir like : var/www/project_name]/bin/magento setup:di:compile

  • i ran setup upgrade @Aashish..i dont think we need to run di:compile each time...its not working..i still get blank page
    – Sushivam
    Aug 16, 2016 at 11:50
  • After upgrade or making any di.xml its necessary to run compilation. Aug 16, 2016 at 11:52
  • I ran...i still get blank page after di:compile, clear var gen, cache
    – Sushivam
    Aug 16, 2016 at 11:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.