LayoutTemplatePath: "~/WidgetTemplates/SearchBox.ascx" (relative path to your template)"
I want to add a separate search for my forums but I need it to be styled differently. How do I accomplish this? When I drop a search control on the forums page it is styled the same as the site wide search. Is there some place else I can register these layouts so they only apply to a specific search control?
Yes, I understand that setting the template from Controls->ViewMap applies the change globally. I've read through the documentation and the only other place I have found that allows me to set a search template is under Settings->Toolboxes->PageControls->Sections->Search->Tools->Search. But when I set the Layout Template to the path of my user control and save, the changes are not reflected on the frontend.
What else can I do?
I have exact same requirements.
I already created a custom template for the searchbox and set the ViewMap, same as @Jeff describes in the post. That template is for the searchbox displayed in the header and set to use a generic index.
I also need a few more searchboxes to be placed in different regions of the page, and each would be set to use different indexes. So I'd prefer to use different placeholder text, different styles for those additional searchboxes.
Yet, I haven't found any way to map multiple templates and use them for different purposes.
Any update on this topic?
Once there would be an Advanced button allowing us to define a template path for each search-box, it'll be much easier for sure.
Right now, I embed my custom searchboxes in widget templates (i.e. blog list template) and it works. But this is not the ideal solution, just a workaround.
If someone out there need this workaround until this bug is fixed on a stable release...
Simply add following in your widget template:
And don't forget to include: