Tell us what you are trying to do?
I have Repeating Custom Field: Embedded Media, where I insert YouTube Videos.
I tried to set it up in the following way:
[wpv-for-each field="wpcf-embedded-youtube"]
<div style="">[types field='embedded-youtube' ][/types]</div>
[/wpv-for-each]
I also tried:
[wpv-for-each field="embedded-youtube"]
<div style="">[types field='embedded-youtube' ][/types]</div>
[/wpv-for-each]
Both doesn't work. The videos only show up, if I use the following setup:
[types field='embedded-youtube' separator='<br/>'][/types]
I'm a bit unhappy with that solution, because there is no white space between the youtube videos. I also tried <br/><br/> as separator, but it doesn't change anything..
Is there any documentation that you are following?
https://toolset.com/forums/topic/repeater-field-line-breaks/
https://toolset.com/documentation/customizing-sites-using-php/functions/#embedded-media
https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-for-each
Is there a similar example that we can see?
In the documentation
What is the link to your site?
Site under development
Hello,
I have tried the same codes you mentioned above in my localhost with a fresh WP installation + the latest version of Toolset plugins, using below steps:
1) Create a repeating Embedded Media field "embedded-youtube"
2) Create a post, display a shortcode block:
[wpv-for-each field="wpcf-embedded-youtube"]
<div style="">[types field='embedded-youtube' ][/types]</div>
[/wpv-for-each]
It works fine in front-end, see my screenshot: embedded.JPG
Is there any missing?
I suggest you check these:
1) If you are using Blocks editor, please put those shortcodes into a shortcode block
https://wordpress.org/support/article/shortcode-block/
2) Make sure you are using the latest version of Toolset plugins, you can download them here:
https://toolset.com/account/downloads/
3) In case it is a compatibility problem, please deactivate all other plugins, and switch to wordpress default theme 2020, deactivate all custom PHP/JS code snippets, and test again
Thanks Luo. There was a compatibility problem with another plugin.
The problem is now solved 🙂