I want to create an XML file that can list multiple entries - straightforward enough. But for each entry, I also want to list all of the sibling entries chosen in the Playa field for that entry. That's where things get tricky.
Putting the Playa content directly into the XML field gets no listing of the Playa choices at all, but when I tried embedding a template...I only see something that looks like (but isn't) the closing XML tag, not the beginning XML tag nor any of the expected Playa children (related titles).
What am I doing wrong?
The code for the primary XML-generation template is:
<root>{exp:channel:entries channel="spc-content" category="5" orderby="title" status="Migrated" sort="asc" limit="100"}
<entry>
<title>{title}</title>
<related>{embed="group/embed-xml-related" the_id="{entry_id}"}</related>
</entry>
{/exp:channel:entries}
</root>
The code for that embedded template is
{exp:playa:children field="playa" entry_id="{embed:entry_id}" limit="15" status="open|Featured|Created|Migrated"}
{title}
{/exp:playa:children}
The output is:
<root>
<entry>
<title>TKB Trading’s Blush Beige</title>
<related/>
</entry>
<entry>
<title>TKB Trading’s Bolera</title>
<related/>
</entry>
<entry>
<title>TKB Trading’s Brilliant Gold</title>
<related/>
</entry>
...
(and so on, until it lists 100 entries)
...
</root>
{exp:playa:children}
tag, not the{exp:playa:siblings}
tag.the_id="{entry_id}"
in your embed tag, but then calling the variable like so:{embed:entry_id}
. You should be calling{embed:the_id}
in your embed.