If you look at the json+ld in the head of your document it is not easy to read (as a human) due to all the escape characters. Are they needed? Looking at the spec it appears we have gone a step too far with escaping the slashes
https://w3c.github.io/json-ld-syntax/#restrictions-for-contents-of-json-ld-script-elements
<script type="application/ld+json">{"@context":"https:\/\/schema.org","@graph":[{"@type":"Organization","@id":"https:\/\/j5.test\/#\/schema\/Organization\/base","url":"https:\/\/j5.test\/"},{"@type":"WebSite","@id":"https:\/\/j5.test\/#\/schema\/WebSite\/base","url":"https:\/\/j5.test\/","name":"5 alive","publisher":{"@id":"https:\/\/j5.test\/#\/schema\/Organization\/base"},"potentialAction":{"@type":"SearchAction","target":"https:\/\/j5.test\/index.php\/en\/search?q={search_term_string}","query-input":"required name=search_term_string"}},{"@type":"WebPage","@id":"https:\/\/j5.test\/#\/schema\/WebPage\/base","url":"https:\/\/j5.test\/index.php\/en\/","name":"Home","description":null,"isPartOf":{"@id":"https:\/\/j5.test\/#\/schema\/WebSite\/base"},"about":{"@id":"https:\/\/j5.test\/#\/schema\/Organization\/base"},"inLanguage":"en-GB"}]}</script>
<script type="application/ld+json">{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://j5.test/#/schema/Organization/base","url":"https://j5.test/"},{"@type":"WebSite","@id":"https://j5.test/#/schema/WebSite/base","url":"https://j5.test/","name":"5 alive","publisher":{"@id":"https://j5.test/#/schema/Organization/base"},"potentialAction":{"@type":"SearchAction","target":"https://j5.test/index.php/en/search?q={search_term_string}","query-input":"required name=search_term_string"}},{"@type":"WebPage","@id":"https://j5.test/#/schema/WebPage/base","url":"https://j5.test/index.php/en/","name":"Home","description":null,"isPartOf":{"@id":"https://j5.test/#/schema/WebSite/base"},"about":{"@id":"https://j5.test/#/schema/Organization/base"},"inLanguage":"en-GB"}]}</script>
Labels |
Added:
No Code Attached Yet
|
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2023-07-25 21:02:54 |
Closed_By | ⇒ | HLeithner |
funny I added this code for better debugging in the system plugin:
$schemaString = $schema->toString('JSON', ['bitmask' => JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE]);