From 4e285ed0389d74d8c58d0b86cafdbbe990b2934b Mon Sep 17 00:00:00 2001 From: Yannick Armand Date: Fri, 23 Feb 2024 18:02:18 +0100 Subject: [PATCH 1/2] Search: fix string for translation --- templates/catalog/listing/search.tpl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/catalog/listing/search.tpl b/templates/catalog/listing/search.tpl index dc7002558..06d106734 100644 --- a/templates/catalog/listing/search.tpl +++ b/templates/catalog/listing/search.tpl @@ -18,10 +18,10 @@ {l s='Nothing to search for' d='Shop.Theme.Catalog'} {else} {if $listing.products|count} - {l s='Search results for' d='Shop.Theme.Catalog'} + {l s='Search results for "%search_term%"' sprintf=['%search_term%' => $smarty.get.s] d='Shop.Theme.Catalog'} {else} - {l s='No search results for' d='Shop.Theme.Catalog'} - {/if} "{$smarty.get.s}" + {l s='No search results for "%search_term%"' sprintf=['%search_term%' => $smarty.get.s] d='Shop.Theme.Catalog'} + {/if} {/if} {/block} From a3647ed7cd24f9831a507e6b6bfd463bd242ea50 Mon Sep 17 00:00:00 2001 From: Yannick Armand Date: Fri, 23 Feb 2024 20:38:16 +0100 Subject: [PATCH 2/2] Search: use `$search_string` instead of `$smarty.get.s` --- templates/catalog/listing/search.tpl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/catalog/listing/search.tpl b/templates/catalog/listing/search.tpl index 06d106734..6aa625800 100644 --- a/templates/catalog/listing/search.tpl +++ b/templates/catalog/listing/search.tpl @@ -14,13 +14,13 @@ {block name='product_list_header'}

- {if empty($smarty.get.s)} + {if empty($search_string)} {l s='Nothing to search for' d='Shop.Theme.Catalog'} {else} {if $listing.products|count} - {l s='Search results for "%search_term%"' sprintf=['%search_term%' => $smarty.get.s] d='Shop.Theme.Catalog'} + {l s='Search results for "%search_term%"' sprintf=['%search_term%' => $search_string] d='Shop.Theme.Catalog'} {else} - {l s='No search results for "%search_term%"' sprintf=['%search_term%' => $smarty.get.s] d='Shop.Theme.Catalog'} + {l s='No search results for "%search_term%"' sprintf=['%search_term%' => $search_string] d='Shop.Theme.Catalog'} {/if} {/if}