How can I fetch a image from a specific field?
My field is called
bild: label: Bild type: files empty: No images selected yet! max: 1 layout: cards
This just gives me the first image of the page, but not the image I want:
<?php if($image = $page->image()): ?> <img srcset="<?= $image->url() ?>" /> <?php endif ?>
bild here gives me errors:
<?php if($image = $bild->image()): ?>
I was building onepagers before with Kirby but didn’t have this problem somehow. Seems very basic, so I guess, I don’t understand some important basics here.
Can anyone help?