Find the page name from id, passed by content picker
Hello,
I have content picker property on a document type. I want to create a link in the macro by passing the id which is selected by the user. How should i proceed. I have alias name for the content picker as "imageLink1". I want to create a link via macro using xslt. The macro is parameterized and alias name for parameter is "moreInfoId".
If you wish to pass a parameter into a macro you should use the following syntax:
[#PageTitle] = get propertyAlias [$PageTitle] = get propertyAlias Recursivly [@yourQueryString] = get request collection, e.g. a query string [%cookieName] = get cookie
Find the page name from id, passed by content picker
Hello,
I have content picker property on a document type. I want to create a link in the macro by passing the id which is selected by the user. How should i proceed. I have alias name for the content picker as "imageLink1". I want to create a link via macro using xslt. The macro is parameterized and alias name for parameter is "moreInfoId".
<umbraco:Macro moreInfoId="<umbraco:Item field="imageLink1" runat="server" />" Alias="GetHomeAdvertLink" runat="server"></umbraco:Macro>
I want this macro to return a link with the nodename. Please guide, what will be my xslt for this. Thanks a lot
If you wish to pass a parameter into a macro you should use the following syntax:
[#PageTitle] = get propertyAlias
[$PageTitle] = get propertyAlias Recursivly
[@yourQueryString] = get request collection, e.g. a query string
[%cookieName] = get cookie
Reference: https://github.com/umbraco/Umbraco4Docs/blob/master/Documentation/Reference/Templating/Macros/index.md
XSLT and Macro Parameters Super Star Speedy Guide :)
http://our.umbraco.org/wiki/reference/templates/umbracomacro-element/macro-parameters
is working on a reply...