Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Nested Component
michael_mohr
I was wondering if it is possible to nest components? For example, I build a component to read an XML feed of title, message and image URL.
I then realize I need a group of these displayed so I create a container component that will utilize the component described above. If the container is given three titles, messages and urls it creates three of the above components and displays them one above the other.
Find more posts tagged with
Comments
AlexC
I'll attach my reply for completeness:
---
You would need 1 component and an external that generates the XML data, then apply XSL against it and iterate over the XML data, you can use xsl:apply-template to do that.
Something like this for displaying all Context/Text types:
At the moment we do not support component in a component due to the structure of the rendering engine, but having the ability to generate this content dynamically using a Prefix/External call and keeping the same XSL template may accomplish what you are looking for.
liv2luv
Alex waiting to see your code, please preview before you submit.
Thanks
kaalraa
Extracted Code:
{xsl:apply-template select="Content"}
{b}{xsl:value-of select="Text"/}{/b}
{/xsl:apply-template}
Change the curly braces with angle braces.
There could be an issue in Devnet, as this code is getting previewed correctly, however not getting submitted.
AlexC
Thanks, the board strips out less thans and if you use & lt; they get changed at preview so you have to actually not submit at preview rather go back and submit. My bad.