Can a slot call a slot?
Here is some sample content used to help me express my example.(Forgive my xml if it’s not correct, just needed something to work with below…:p)
<slot id=1>content id 2</slot>
<slot id=2>content id 3</slot>
So, I have a template for content 1. This template calls slot 1. The snippet used for slot 1, displays content 2’s displaytitle. This part works fine. But, when I put in that snippet a slot call(to display content 3), I get a rollback exception. Now, if I use that snippet to display content 2 directly(w/out going through content 1), it works properly and I can display content 3.
Can you call a slot on an item returned by a slot?
Yes, a slot can contain a Snippet which in turn contains another slot. Don’t get carried away (because assembly performance suffers when you do this too much), but for 2 or 3 levels you should be fine.
The most common cause of this failing is that the snippets should be “well-formed” XHTML, complete with <html>, <head> and <body> tags. If a snippet works “by itself” and then fails in a slot, it’s usually because it’s not well-formed.
BTW, this is also true of body fields that contain inline templates: they must also be well-formed.
I don’t really know if this is your problem, but based on your description, it sounds like something you should check.
It turns out I had a problem with my slot. When I had the order_by parameter filled out, I would get an unexpected token exception when I would call it within a slot. When I removed it, I could now call it within a slot. Thanks!