Laza,
I did try that in the past and I had the same issues reported by Google. According to resources on-line the line has to look like this:
<link rel="canonical" href="https://yoursite.com/your-page-url"
I did try
<link rel="canonical" href="${albumURL}/${pageUrl}">
BUT the albumURL only worked for level 0, level 1 down it was missing in action!
This is probably more complex than needed but I'm not a programmer but I do understand programming principles. Also, according to the on-line help using Lightbox was an issue because it flattened to a single level all the graphics files. So with on-line AI help I came up with this to resolve both issues. (Don't laugh at me to hard, please!!)
<link rel="canonical" href="https://Your.Website-URL.com/${currentFolder.pathFromRoot}<ja:if test="${currentFolder.pathFromRoot}" value=""></ja:if><ja:else>/</ja:else>">
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "ImageGallery",
"name": "${albumTitle}",
"description": "${albumDescription}",
"url": "https://Your.Website-URL.com/${currentFolder.pathFromRoot}<ja:if test="${currentFolder.pathFromRoot}" value=""></ja:if><ja:else>/</ja:else>",
"hasPart": [
<ja:fileiterator>
{
"@type": "ImageObject",
"name": "${title}",
"description": "${comment}",
"contentUrl": "https://Your.Website-URL.com/${currentFolder.pathFromRoot}<ja:if test="${currentFolder.pathFromRoot}" value=""></ja:if><ja:else>/</ja:else>${fileName}",
"thumbnail": {
"@type": "ImageObject",
"contentUrl": "https://Your.Website-URL.com/${currentFolder.pathFromRoot}<ja:if test="${currentFolder.pathFromRoot}" value=""></ja:if><ja:else>/</ja:else>thumbs/${fileName}"
}
}${ja:iflast}${else},${ja:endif}
</ja:fileiterator>
]
}
</script>
And this created the correct href= for every page and all are unique to that page.
Edited by: nigel-aves on 28 Aug 2026, 09:55
Edited by: nigel-aves on 28 Aug 2026, 10:17