Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, Ed, biapar, Willr, Ingo, swaiba

Cant show FormattedCoverImage

Go to End

3 Posts   745 Views


Community Member, 31 Posts

16 September 2011 at 11:20pm


I have DOM+Uploadify+ImageGalery installed on my site. The gallery shows images propertly, but when i show alist of galleries, i can see the Cover Images. Or when i change delete <if CoverImage> in AlbumList, i can see some Cover Images.

So, I have two problems.
When I have code

<% if CoverImage %>
					<% control FormattedCoverImage %>
						<img src="$CoverImage">
					<% end_control %>
				<% else %>
					<span class="no-image"></span>
				<% end_if %>

I can't see Cover Images. In the codeit give me no-image class. When I delete the requirement, i CAN see the CoverImage.

In some galleries i can set CoverImage. But in the others I set it, save it and when I refresh it, it show me no-CoverImage. I don't know if I make some mistakes, or if it's something wrong.


Forum Moderator, 4102 Posts

17 September 2011 at 2:02am

FormattedCoverImage() returns an Image object, so you want $URL in that src attribute.

SilverStripe tips, tutorials, screencasts and more:


Community Member, 31 Posts

17 September 2011 at 2:14am

Thanks, my mistake. Now I have correct CoverImage, so the SECOND problem i had=fixed. Now i work on repair the FIRST problem.