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
Document types: - overview page (no extra properties) - child page: (richtext fulltext, richtext introduction, mediapicker picture) Document layout: - overview page -- child page Goal: Show a small introduction and picture of all the child pages on the overview page. [code] [/code] this code gives an error @ Would like to know how to get the image from the childpage media picker.
Is the error reported when saving the xslt , or on the front end? If the problem arises when saving: Try skipping testing when saving the xslt. There is a checkbox for that. For a more permanent fix do like this: Notice the if test around the img tag. GetMedia fails if there is no media id supplied, and when testing on save it is tested against a fake xml doc that may not contain that property.
The error was while saving so your solution worked. Aha didn't know the tester tested against a fake xml doc. Feel stupid I never tried to save while skipping errors :) Thanks for the quick help! +1 to my Umbraco experience points ^^
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
Load Media Item From Child Page
Document types:
- overview page (no extra properties)
- child page: (richtext fulltext, richtext introduction, mediapicker picture)
Document layout:
- overview page
-- child page
Goal:
Show a small introduction and picture of all the child pages on the overview page.
[code]
[/code]
this code gives an error @
Would like to know how to get the image from the childpage media picker.
Is the error reported when saving the xslt , or on the front end?
If the problem arises when saving:
Try skipping testing when saving the xslt. There is a checkbox for that.
For a more permanent fix do like this:
Notice the if test around the img tag.
GetMedia fails if there is no media id supplied, and when testing on save it is tested against a fake xml doc that may not contain that property.
The error was while saving so your solution worked.
Aha didn't know the tester tested against a fake xml doc.
Feel stupid I never tried to save while skipping errors :)
Thanks for the quick help!
+1 to my Umbraco experience points ^^
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.