-
-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
og:url and twitter:url referencing Blitz cache token #457
Comments
For now, I've ended up using a custom SEO meta template so I can override those tags using this instead |
Thanks for jumping on a fix for this so quickly @Tam really appreciated it. It looks to be working pretty well for my use case so far, the only thing I'm wondering about is that my URLs are now left with a lonely Thanks |
Description
We have a site that uses Ether SEO and the full-page caching Blitz plugin.
When Bltz is generating the cache it adds a token parameter to the URL which is being saved to the og:url and twitter:url meta tags within the SEO meta template because they use
{{ craft.app.request.absoluteUrl }}
. Based on this discussion on the Blitz repo and the warning provided in the Craft 4 class reference docs for this method it seems this isn't recommended.The result of having the
?token=...
parameter cached to those SEO tags is that the canonical URL that Facebook and Twitter/X are using is incorrect and results in no preview data (title, image description etc) being pulled through.Is there an alternative to
{{ craft.app.request.absoluteUrl }}
that can be used?Thanks
Additional info
The text was updated successfully, but these errors were encountered: