From 9a42e4b068f756b54476c88d7e36786899034104 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Thu, 20 Jan 2022 11:50:19 +0100 Subject: [PATCH] Stop using `|encodeJSON` (cherry picked from commit ab1e34de9ca94dc44b20d0b4d58eca2bad80d9d3) --- com.woltlab.wcf/templates/ampArticle.tpl | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/com.woltlab.wcf/templates/ampArticle.tpl b/com.woltlab.wcf/templates/ampArticle.tpl index fc04826a6b..c33e738140 100644 --- a/com.woltlab.wcf/templates/ampArticle.tpl +++ b/com.woltlab.wcf/templates/ampArticle.tpl @@ -5,21 +5,21 @@ { "@context": "http://schema.org", "@type": "NewsArticle", - "mainEntityOfPage": "{@$regularCanonicalURL|encodeJSON}", - "headline": "{@$articleContent->title|encodeJSON}", + "mainEntityOfPage": {@$regularCanonicalURL|json}, + "headline": {@$articleContent->title|json}, "datePublished": "{@$article->time|date:'c'}", "dateModified": "{@$article->time|date:'c'}", - "description": "{@$articleContent->getFormattedTeaser()|encodeJSON}", + "description": {@$articleContent->getFormattedTeaser()|json}, "author": { "@type": "Person", - "name": "{@$article->username|encodeJSON}" + "name": {@$article->username|json} }, "publisher": { "@type": "Organization", "name": "{PAGE_TITLE|language}", "logo": { "@type": "ImageObject", - "url": "{@$__wcf->getStyleHandler()->getStyle()->getPageLogo()|encodeJSON}", + "url": {@$__wcf->getStyleHandler()->getStyle()->getPageLogo()|json}, "width": {@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoWidth')}, "height": {@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoHeight')} } @@ -27,7 +27,7 @@ {if $articleContent->getImage()} ,"image": { "@type": "ImageObject", - "url": "{@$articleContent->getImage()->getThumbnailLink('large')|encodeJSON}", + "url": {@$articleContent->getImage()->getThumbnailLink('large')|json}, "width": {@$articleContent->getImage()->getThumbnailWidth('large')}, "height": {@$articleContent->getImage()->getThumbnailHeight('large')} } -- 2.20.1