I'm facing a problem......
I have a page with children, the children have a content picker...
what I want to get is : the image in the page that selected in the content picker for each child page.
P.S: can only choose one page in the content picker.
what i achieved is :
IPublishedContent currentScene = Umbraco.TypedContent(CurrentPage.Id);
IEnumerable<IPublishedContent> Pins = currentScene.Children();
foreach (var pin in Pins)
{
var Thumbid = @pin.GetPropertyValue("pinPicture");
var Thumburl = Umbraco.Media(Thumbid.ToString()).Url;
<img id="@pin.Name -thumb" crossorigin="anonymous" src="@Thumburl">
var typedMultiNodeTreePicker1 = @pin.GetPropertyValue("link");
var page = Umbraco.Content(@typedMultiNodeTreePicker1);
<img id="@page.Name" crossorigin="anonymous" src="">
}
the typedMultiNodeTreePicker1 is the node id but i can't get the name on any values from it .....
can someone help me.
get content picker value from child page
Hi guys,
I'm facing a problem...... I have a page with children, the children have a content picker... what I want to get is : the image in the page that selected in the content picker for each child page.
P.S: can only choose one page in the content picker.
what i achieved is :
the typedMultiNodeTreePicker1 is the node id but i can't get the name on any values from it ..... can someone help me.
Hi ٌ
Multi Node Tree Pickers return a value of IEnumerable
Also, you are jumping between dynamics and typed content which isn't very good. You should try and stick with TypedContent.
Try the following:
Thanks
Nik
is working on a reply...