Show a custom block when a search term is entered

27/06/2018


Using Drupal 8 and Solr
I’d like to show a custom text block when a user enters a specific search term on the search page.

When a user types in a search term, the query is posted in the URL (ex: http://myurl.com/search?search_api_fulltext=apples&sort_by=field_date&sort_order=DESC). I thought I would be able to add a custom text block to this URL. However, it doesn’t seem to work. I am able to add the custom block to /search, so I know the block itself is working. Any ideas how to do this (and/or why it might not work)?

قالب وردپرس