Retrieve content from homepage node to be displayed on sub pages.
Hi All,
I have a multiligual site which has on the home page a tab where the contact details of the office is entered.
on each country site the phone number will be diplayed through out the site.
eg UK will be 123456789 Germany will be 987654321 Netherlands will be 147852369
I can get this pulled through no problem on the homepage but all the other pages it disappears. So what I am asking is there a way of getting the content to be displayed on all pages even if the content is on the homepage?
Hi Tom, do you want to display exactly the same info on your different multilingual pages, or coutry-specific info on the related pages? How do you currently display the info on the homepage (the main page, I guess) ?
Or, make sure to use recursive="true" so umbraco will look up the value on ancestors until it finds a value. If those props are defined on the top level node, it will taken from there.
Retrieve content from homepage node to be displayed on sub pages.
Hi All,
I have a multiligual site which has on the home page a tab where the contact details of the office is entered.
on each country site the phone number will be diplayed through out the site.
eg
UK will be 123456789
Germany will be 987654321
Netherlands will be 147852369
I can get this pulled through no problem on the homepage but all the other pages it disappears. So what I am asking is there a way of getting the content to be displayed on all pages even if the content is on the homepage?
Thanks
Tom
Hi Tom, do you want to display exactly the same info on your different multilingual pages, or coutry-specific info on the related pages? How do you currently display the info on the homepage (the main page, I guess) ?
>Tommy
there are two approaches: using the masterpage for the frontpage and a submasterpage for the other content
or you are using xslt via $currentNode/ancestor-or-self::node [level=1]/data [@alias='alias of your values of the frontpage']
Thomas
Or, make sure to use recursive="true" so umbraco will look up the value on ancestors until it finds a value. If those props are defined on the top level node, it will taken from there.
Cheers,
/Dirk
Hi Dirk,
Thanks for that, I have tried that but I keep on getting the following error
>>> <xsl:value-of select="@contactNumber" recursive="true" /> <<<
Any idea's why this maybe?
Tom
I think Dirk has had a long day, what he meant was to use this directly from with your template/masterpage, like so:
Cheers Seb,
That was perfect :)
is working on a reply...