Image included in the form

I am creating a form that should contain two images, I am working with

             type: section
             title_level: p

like h1, p, div

However, img or image type simply does not work for me and if it does, I cannot fill it with the correct path to the image, I tried path:, src:, url:

I would assume it would work like this:

       type: section
       title_level: img
       url: /templates/images
       classes: col-12

I can’t believe I can’t figure it out, but it’s been two hours now and I still haven’t found the correct format.

Please, how can I generate an image in the form?
Thank you for your help.

@Deight, field section does not allow Markdown as a value for property title. But field display does and might fit your needs…

  name: myform
      type: display
      size: large
      label: Show me an image
      markdown: true
      content: "![My Image](/user/themes/quark/images/favicon.png)"

The value of property size is just a class added to the outer element and can be used to resize the image using css.


Thank you very much, I was expecting a simpler procedure, but the main thing is that it works. Thank you once again!

1 Like