I have an entry in the section microsites these entries all have a required field called accessCode. I have the access code in a variable. I want to load in only that entry. Is this possible without a for loop?

The end result would like something like this:

{% set entries = craft.entries ({
    section: 'micrositeEntries',
    with: 'accessCode', ('Im not sure how to look for the exact entry') ('my variable would be aCode ')
}).first() %} 

{% set image = entries.cImage[0] ?? null %}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.