0

Typo3 project. I installed the Solr Search extension. In the backend, it is possible to add a search block as a content element. But I need to insert a search block in the layout header. How can this be done?

I've tried inserting a form in the Header block, but that doesn't work.

Dmitriy
  • 7
  • 3

1 Answers1

0

When you only want to have an input field, you need a simple HTML or Fluid form targeting to your search result page and using the correct GET parameters:

<form action="/results">
    <input type="text" name="tx_solr[q]" value="" />
</form>
Thomas Löffler
  • 5,922
  • 1
  • 14
  • 29
  • I put the html block, there is a transition to the result page, but the result is missing. – Dmitriy Mar 30 '23 at 17:11
  • Do you have stuff in the Solr index? Are there results when you use the Solr plugin? – Thomas Löffler Mar 31 '23 at 08:34
  • No. I have an error in Apache Solr/Info: Unable to contact the following Apache Solr servers. I used Hosted Solr. But I don't have other page result elements like label, title, paginator etc. In case of using this extension (Solr) like content element I get labels, paginator, title but without search result. – Dmitriy Mar 31 '23 at 13:44