I am trying to: I use a plugin called Soliloquy to build sliders. It allows me to build Dynamic Sliders thanks to their Dynamic Addon. to that that, I need simply need to build a shortcode that would have the following form:
[soliloquy_dynamic id="custom-XXX" images="hidden link"]
I'll try to make things simple to explain my situation:
I built a Custom Post Type that I called "Websites" with a Custom Field that is an image that I called "Homepage Screenshot"
I'd like to use the URLs of those Homepage Screenshots to populate the "images" attribute of the Soliloquy Shortcode separated with commas, with no spaces between them.
To do so, I built a View that should output the expected Shortcode populated with the images URLs. Here is what it looks like:
[wpv-layout-start]
[wpv-items-found]
<!-- wpv-loop-start -->
[soliloquy_dynamic id="custom-XXX" images="
<wpv-loop>
[wpv-item index=1]
[types field='screenshot-homepage' size='full' url='true'][/types]
[wpv-item index=other]
,[types field='screenshot-homepage' output='raw'][/types]
</wpv-loop>
"]
<!-- wpv-loop-end -->
[/wpv-items-found]
[wpv-no-items-found]
<strong>[wpml-string context="wpv-views"]No items found[/wpml-string]</strong>
[/wpv-no-items-found]
[wpv-layout-end]
I visited this URL:
I expected to see the output of this to be something like:
[soliloquy_dynamic id="custom-XX2" images="<em><u>hidden link</u></em>"]
Instead, I got:
[soliloquy_dynamic id="custom-XX2" images=" <em><u>hidden link</u></em> ,<em><u>hidden link</u></em> ,<em><u>hidden link</u></em> ,<em><u>hidden link</u></em> ,<em><u>hidden link</u></em> ,<em><u>hidden link</u></em> ,<em><u>hidden link</u></em> "]
So I get a bunch of empty spaces before or after each outputted item.
Is there a way to have the same output result but without the added empty spaces that break the Soliloquy Shortcode for Dynamic Sliders?
In Case you are wondering why I'd like to use that Soliloquy plugin to build my slider, the answer is simple, it allows to build simple responsive Sliders with a lot of options that I can't find on Views plugin for now.
If anyone could help me get rid of those empty spaces, it would be really awesome.