cancel
Showing results for 
Search instead for 
Did you mean: 

Add Magento search on Home Page banner

Add Magento search on Home Page banner

I want to add a search box on the home page banner like this

GmQLc.png

I added this banner via page-builder. Any way-out to add search box like this? Please guide

1 REPLY 1

Re: Add Magento search on Home Page banner

Add Search Form

app/code/VendoreName/ModuleName/Helper

Data.php

<?php
namespace VendoreName\ModuleName\Helper;
use Magento\Framework\App\Helper\AbstractHelper;
class Data extends AbstractHelper
{
protected $searchConfigProvider;

public function __construct(
\Magento\Search\ViewModel\ConfigProvider $searchConfigProvider
) {
$this->searchConfigProvider = $searchConfigProvider;
}

public function getSearchconfigProvider()
{
return $this->searchConfigProvider;
}

}

A detailed answer can be found here

If issue solved, Click Kudos & Accept as Solution.
LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool