-
Notifications
You must be signed in to change notification settings - Fork 1
Images not found if Flexible field is in a Repeater field #7
Comments
Hi @tmconnect, To clarify a little bit, you are using flexible fields into a repeater one ? Thank you for your kindness and code proposal. |
Thanks for your reply. Yes - I have a "pagebuilder system" which has a repeater where the user can add rows to build his page. Within this repeater - and therefore in each row - is a flexible content field with a lots of layouts the user can select from. |
Great ! I'll have a look closely soon then. |
Hi @tmconnect, Could you please check that this version (https://github.com/BeAPI/bea-beautiful-flexible/archive/issue-7.zip) include your changes and works well in your case ? You will be kind, thank you 😄 |
Thanks for the new version, but I got an error - even if the flexible content field is not in repeater: After delving a bit deeper into your code, I found a much simpler solution for the implementation: Because each popup item already has a data-layout attribute, which tells the name of the layout element. You don't have to get the names of all flexible layouts in an extra function. The JS script only has to get this data-layout attribute and has to modify the acf-popup list. In addition I wrote some data attributes to the acf-popup element for the title and subtitle for the popup. So the strings can be translated. You can download my solution from my dropbox: Link Let me know if this works for you. Thomas |
Hi @tmconnect, |
This plugin is deprecated. |
First of all: Great work!
But the images for the popup are not found if the Flexible field is in a Repeater field.
I found a solution for an existing scenario on my site, but I don't know if this is the correct way for all. I changed the
foreach ( $fields as $field )
loop in theretrieve_flexible_keys
function to this:Hope, this helps for further development.
Thomas
The text was updated successfully, but these errors were encountered: