From f58346626cc5802ffd97a52d9533a9d505d80d6d Mon Sep 17 00:00:00 2001 From: Jon Kariko Date: Mon, 18 Jul 2016 08:47:19 -1000 Subject: [PATCH] Enhance 404 Page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Makes 404.liquid layout consistent with page.liquid. Changes error subtext to be less accusatory. Replaces anchor link with a button to clarify “Continue Shopping” call-to-action, but all non-English locales are Google translated and should be checked for accuracy. Adds recent articles from index.liquid as suggested by Google Webmaster resources (https://goo.gl/1n5W8S). --- locales/de.json | 3 ++- locales/en.default.json | 3 ++- locales/es.json | 3 ++- locales/fr.json | 3 ++- locales/pt-BR.json | 3 ++- locales/pt-PT.json | 3 ++- templates/404.liquid | 53 +++++++++++++++++++++++++++++++++++++++-- 7 files changed, 63 insertions(+), 8 deletions(-) diff --git a/locales/de.json b/locales/de.json index bcf7ec7f9..8de359af0 100644 --- a/locales/de.json +++ b/locales/de.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 Seite nicht gefunden", - "subtext_html": "Die von Ihnen angeforderte Seite existiert nicht. Klicken Sie hier, um den Einkauf fortzusetzen." + "subtext_html": "Die von angeforderte Seite existiert nicht.", + "continue_html": "Einkauf fortfahren" }, "breadcrumbs": { "home": "Startseite", diff --git a/locales/en.default.json b/locales/en.default.json index 3f765d262..094f84b3e 100644 --- a/locales/en.default.json +++ b/locales/en.default.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 Page Not Found", - "subtext_html": "The page you requested does not exist. Click here to continue shopping." + "subtext_html": "The page requested could not be found.", + "continue_html": "Continue Shopping" }, "breadcrumbs": { "home": "Home", diff --git a/locales/es.json b/locales/es.json index 8c6be51fd..a7858930f 100644 --- a/locales/es.json +++ b/locales/es.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 Página no encontrada", - "subtext_html": "La página que ha solicitado no existe. Haga clic aquí para continuar la compra." + "subtext_html": "La página solicitado no existe.", + "continue_html": "Continuar Compras" }, "breadcrumbs": { "home": "Inicio", diff --git a/locales/fr.json b/locales/fr.json index 0071e26cd..81ec2833c 100644 --- a/locales/fr.json +++ b/locales/fr.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 - Page non trouvée", - "subtext_html": "Cette page n'est pas disponible. Retourner au magasinage" + "subtext_html": "Cette page n'est pas disponible.", + "continue_html": "Continuer achats" }, "breadcrumbs": { "home": "Accueil", diff --git a/locales/pt-BR.json b/locales/pt-BR.json index cc8de5429..080911c1b 100644 --- a/locales/pt-BR.json +++ b/locales/pt-BR.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 Página não encontrada", - "subtext_html": "A página que você solicitou não existe. Clique aqui para voltar às compras." + "subtext_html": "A página solicitou não existe.", + "continue_html": "Continuar compras" }, "breadcrumbs": { "home": "Início", diff --git a/locales/pt-PT.json b/locales/pt-PT.json index fa5a4e0d5..a82345ed4 100644 --- a/locales/pt-PT.json +++ b/locales/pt-PT.json @@ -6,7 +6,8 @@ }, "404": { "title": "404 Página Não Encontrada", - "subtext_html": "A página que solicitou não existe. Clique aqui para continuar as suas compras." + "subtext_html": "A página não existe.", + "continue_html": "Continuar compras" }, "breadcrumbs": { "home": "Início", diff --git a/templates/404.liquid b/templates/404.liquid index dfabc3a8f..0b009e46c 100755 --- a/templates/404.liquid +++ b/templates/404.liquid @@ -1,3 +1,52 @@ -

{{ 'general.404.title' | t }}

-

{{ 'general.404.subtext_html' | t }}

+
+
+ +

{{ 'general.404.title' | t }}

+

{{ 'general.404.subtext_html' | t }}

+ {{ 'general.404.continue_html' | t }} + +
+ +

{{ 'homepage.sections.news_title' | t }}

+
+ {% for article in blogs['news'].articles limit:3 %} +
+ + +

{{ article.title }}

+ + {% comment %} + Add a surrounding div with class 'rte' to anything that will come from the rich text editor. + Since this is just a listing page, you can either use the excerpt or truncate the full article. + {% endcomment %} +
+ {% if article.excerpt.size > 0 %} + {{ article.excerpt }} + {% else %} +

{{ article.content | strip_html | truncatewords: 20 }}

+ {% endif %} +
+ + {% comment %} + Show off meta information like number of comments and tags. + {% endcomment %} + + +

{{ 'blogs.article.read_more' | t }} →

+ +
+ {% endfor %} +
+ +
+
\ No newline at end of file