TimOetting / kirby-builder

A site builder extension for Kirby CMS
398 stars 50 forks source link

How to display files in fieldsets? #144

Closed andreasotto closed 2 years ago

andreasotto commented 4 years ago

Kiry 3.3 and the following blueprint:

name: Text
label: Text
fields:
    textitems:
        type: builder
        label: Einträge
        columns: 2
        fieldsets:
            text:
                name: Text
                label: Text
                fields:
                    text:
                        label: Text
                        type: textarea

            image:
                name: Bild
                label: Bild
                fields:
                    image:
                        label: Bild
                        type: files

I don't get the output in the template. I tried with this:

    <?php foreach($section->textitems()->toBuilderBlocks() as $item) : ?>
      ...
    <?php endif ?>

Trying to get the image from $item, but how ..?

TimOetting commented 2 years ago

Closing this issue because this plugin will no longer be maintained, as its main functionality can be replaced by Kirby's built-in Blocks Field and Layout Field.