0

I have a form that accepts one input and after submits redirects to a controller that does some search stuff with solr.

I have discovered some weird behavior when certain words are used as a search term for the parameters of the route:

This is the SearchBoxForm form when the form is submitted, as you see it just redirects to the search controller enter image description here

This is the controller action that accepts the redirect: enter image description here

This is the route file: enter image description here

So as you can see, the url can be as domain.com/search to domain/search/term/tab/page/filter.

No the problem, certain search words causes drupal to not properly load all js, some words are: "cache", "chemistry" but other words work just fine like "student" or "economy".

The page works fine if you hit it with default parameters, ie domain.com/search But domain.com/search/cache or domain.com/search/cache/all/1/undefined will not load js in any way.

Has anyone seen this problem before, or see something obvious that I have missed? I really hope this is not the render array or something that somehow sees cache in the parameters and thinks it something else..

Björn Grunde
  • 55
  • 1
  • 9
  • I'm allways unsure about D8 cache :D I'd make a fast check adding $searchPage['#cache'] = ['max-age' => 0] to see what happend. – miguel-svq Jun 24 '20 at 11:20
  • It would be helpful if you were to add which versions of Solr, Search API, Search API Solr, Drupal, etc ... you are using as the functionality varies quite depending on those. – baikho Jun 24 '20 at 20:50

0 Answers0