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
I use DAMP on my blog. I'd like for the blog home page to show the associated pictures in the summary.
However I can't seem to get the syntax right and after a day of searching have given up.
Its nice and easy I don't want cropping just the path to the image so that I can show an image.
I can't find a method that works.
On my blog page I have a foreach statement that gets the child objects as expected:
nodes = ((IEnumerable<DynamicNode>)posts).Take(count).Skip(0);
@foreach (DynamicNode n in nodes)
<a href="@n.Url" title="@n.GetProperty("ContentTitle").Value">
I want to be able to pick up the image called ContentImage also on that page. Each blog has a DAMP image file associated (ContentImage).
It seems the method I use pickup the single image in the post:
dynamic media = Model.MediaById(Model.uBlogsyContentImage);
<img src="@media.umbracoFile" alt="@media.nodeName" class="blogImage" />
Can't be used as MediaByID only returns a single value.
So my question is this:
How can I pickup each photo for each blog entry
Any help (or pointers) would be gratefully received.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted