Hello!
I am creating a paywall for a blog on my squarespace 7.1 site and have the business plan.
When someone see's the preview of the blog, they see the Title, meta content, and excerpt. Is there a way to also include the featured image in the paywalled blogs preview content?
I have already got the featured image to show at the top of blogs using the following in "blog item code injection":
<style>
div.blog-item-image-wrapper { margin-bottom:12px; }
img.blog-item-image { width:100%; }
</style>
<script>
const i = document.querySelector('meta[itemprop="image"]');
const u = !!i ? i.getAttribute('content') : '';
if (u) {
const c1 = document.querySelector('.blog-item-inner-wrapper');
const c2 = document.querySelector('.blog-item-top-wrapper');
const ed = document.createElement('div');
ed.setAttribute('class','blog-item-image-wrapper');
const ei = document.createElement('img');
ei.setAttribute('class','blog-item-image');
ei.setAttribute('src',u);
ed.appendChild(ei);
c1.insertBefore(ed,c2);
}
</script>
Thank you