My ACF repeater has a image field that returns the URL. In Proforms I add a repeater element with a Bricks image element inside it. The ID of the post I’m editing in the form comes from the uel_parameter:member_id so I have tried;
{brf_acf_field}:{band-member__gallery_image:array}:{url_parameter:member_id}
{brf_acf_field}:{band-member__gallery_image:array:{url_parameter:member_id}}
and many combinations of this, but all I ever get in the SRC of the image on the frontend is ‘{’
Any ideas?
AI is suggesting I cannot have an image in a repeater pro form element and use the standard + and - buttons to manage them. I cannot think a file element is going to work without some JS to show the new image uploaded, and I’m not sure where the file element will store the images anyway.
Hi Pete,
Two things are going wrong here.
First the tag syntax. brf_acf_field is one single tag with colon-separated arguments, so it has to look like {brf_acf_field:band-member__gallery_image:123}, not three tags chained together with colons. And Bricks does not resolve a tag inside another tag, so {url_parameter:member_id} cannot be nested in there. That is why you only ever see the opening brace.
Second, and more important: a Bricks image element inside the Pro Forms repeater is not a form field, so nothing will ever fill it. The repeater brings its own way to load existing data. Select the repeater element and open the “Data” group: Data Source = ACF Repeater, Field Name = your repeater field, Post ID = {url_parameter:member_id} (that control is run through dynamic data, so the tag works there). The child fields are matched by their Custom ID, which must be exactly the ACF sub-field name. Only real inputs get filled - text, textarea, select, checkbox/radio and rich text - so an image sub-field that returns a URL lands in a Text or URL field.
Uploading does work: a File field inside the repeater is supported, and the files go to the media library like everywhere else (there is a “Skip Adding to Media Library” option if you do not want that). What is not supported inside a repeater is “Direct Upload to Server”, and since the “Initial Files” preview depends on that option, the already saved images cannot be shown inside a repeater item.
If the images are really a gallery per member rather than one image per row, the much better fit is an ACF Gallery field plus a single File field outside the repeater: under “Initial Files” set Method = ACF Gallery, Field Name and Post ID. You then get the existing images displayed and new uploads in one control.
To write the rows back, use the Update Post Meta action with “Is Repeater Field” enabled and Repeater Action = “Update Rows (Pro Forms Repeater)”, passing the repeater field with the array filter, e.g. {{my_repeater:array}}.
Kind regards
Daniele