Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: JSON-LD instead of Microdata in default templates
philwareham wrote #303911:
I’m building AMP pages into the new Textpattern.com site (just for the blog articles). You can satisfy the AMP rich snippets image requirement by having a fallback image in your AMP template’s JSON-LD like so:
Yes, I know how to do that, but that fallback image is not really (directly) related to the article, isn’t that a sort of requirement?
I’ve no idea how AMP pages display in G’s search results. I very rarely use Google, much less on a mobile phone which I don’t have, and Google Japan doesn’t seem to work as the Google US in this regard, as far as I can tell.
Where is that emoji for a solar powered submarine when you need it ?
Sand space – admin theme for Textpattern
phiw13 on Codeberg
Offline
Re: JSON-LD instead of Microdata in default templates
Yes, it’s not ideal and I’d encourage all our blog writers to have a unique image per every article, but given that the AMP result snippet simply will not be displayed in Google results unless it has an image associated with it then it’s a fair compromise.
Another reason why I’m not using JSON-LD for the default theme.
Offline
Re: JSON-LD instead of Microdata in default templates
philwareham wrote #303916:
Yes, it’s not ideal and I’d encourage all our blog writers to have a unique image per every article, but given that the AMP result snippet simply will not be displayed in Google results unless it has an image associated with it then it’s a fair compromise.
Another reason why I’m not using JSON-LD for the default theme.
Not so sure about that. JSON-LD is just an object, so we can create an array of object entries into it.
For example, this sample below passes the validation throughout the Google Rich Snippets Testing Tool (https://search.google.com/structured-data/testing-tool):
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "BlogPosting",
"mainEntityOfPage": "http:\/\/example.com\/",
"headline": "Headline",
"datePublished": "2018-06-09T15:09:51Z",
"dateModified": "2018-06-09T15:09:51Z",
"description": "Description",
"articleSection": "Section Title",
"keywords": [
"Category 1",
"Category 2"
],
"image": [
{
"@type": "ImageObject",
"url": "http:\/\/example.com\/images\/1.jpg",
"height": 200,
"width": 300
},
{
"@type": "ImageObject",
"url": "http:\/\/example.com\/images\/2.jpg",
"height": 200,
"width": 300
}
],
"author": {
"@type": "Person",
"name": "Author's Name"
},
"commentCount": 6,
"comment": {
"text": "Comment text",
"author": {
"@type": "Person",
"name": "Bob"
}
},
"publisher": {
"@type": "Organization",
"name": "Blog Name",
"logo": {
"@type": "ImageObject",
"url": "http:\/\/cdn.ampproject.org\/logo.jpg",
"width": 600,
"height": 60
}
}
}
</script>
May be I need to update my JSON-LD collection for Textpattern: https://github.com/cara-tm/JSON-LD/
Last edited by Pat64 (2018-08-16 08:45:48)
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline