Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hey. I've read that you can use variables in templates in macro properties; like:
<umbraco:Macro alias="X" param1="[@umbPageId] param2="[#id]" runat="server" />
However the values coming through for me are 0 (it's an int property). Am I missing something?
Cheers
The concept is correct. (documentation can be found here: http://our.umbraco.org/wiki/reference/templates/umbracomacro-element/macro-parameters/advanced-macro-parameter-syntax)
Did you declare the properties in the macro as well?
HTH
- Sune
Yeah no, cheers, what I wanted was [#pageID]
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Dynamic templates variables
Hey. I've read that you can use variables in templates in macro properties; like:
<umbraco:Macro alias="X" param1="[@umbPageId] param2="[#id]" runat="server" />
However the values coming through for me are 0 (it's an int property). Am I missing something?
Cheers
The concept is correct. (documentation can be found here: http://our.umbraco.org/wiki/reference/templates/umbracomacro-element/macro-parameters/advanced-macro-parameter-syntax)
Did you declare the properties in the macro as well?
HTH
- Sune
Yeah no, cheers, what I wanted was [#pageID]
is working on a reply...