I have been trying to create a general XSLT to display all the content of the datatype by passing in the name of the field it uses in umbraco but so far it isn't displaying anything.
I don't really know what to do with this, i can pass in the name, i can pass in a field of a different datatype but i can't seem to pass in this data type and have the foreach loop run through all the parts of this field. what is wrong with this?
General XSLT for display
I have been trying to create a general XSLT to display all the content of the datatype by passing in the name of the field it uses in umbraco but so far it isn't displaying anything.
I don't really know what to do with this, i can pass in the name, i can pass in a field of a different datatype but i can't seem to pass in this data type and have the foreach loop run through all the parts of this field. what is wrong with this?
and i do know that this foreach code WILL display the list items:
but that doesn't help when i have multiple embedded content fields on a single page and i want to just use one macro to display them all.
Hi mfeola,
To access an element by name (when you don't know the name beforehand) you can use the name() function:
/Chriztian
that works perfectly, just had to change the macro from accepting the field to accepting the field name, thank you :D
is working on a reply...