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.

Customising the CMS /

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

Cant list images in file store

Go to End

3 Posts   846 Views


Community Member, 4 Posts

2 January 2013 at 7:32pm

I have recently upgraded from 2.4 and since then have lost the ability to select images using the TreeDropdownField

when I click on it, nothing happens.


$fields->addFieldToTab('Root.Content.Slides', new LiteralField ($name = "literalfield", $content = "<h2>Left Slide Window</h2>"));
$fields->addFieldToTab('Root.Content.Slides', new LiteralField ($name = "literalfield", $content = "<h4>Slide 1</h4>"));
$fields->addFieldToTab('Root.Content.Slides', new TextField('SlideDescriptionShort1', 'Short description'));
$fields->addFieldToTab('Root.Content.Slides', new TextField('SlideDescriptionLong1', 'Long description'));
$fields->addFieldToTab('Root.Content.Slides', new TreeDropdownField('SlidePage1ID', 'Page', 'SiteTree'));
$fields->addFieldToTab("Root.Content.Slides", new SimpleImageField('SlideImage1', 'Image'));


Community Member, 545 Posts

8 January 2013 at 5:43pm

I may be confused by your questions, is the TreeDropdown notworking or the SimpleImageField? You say you can't slect images with TreeDropdown but your example calls a apge realtion.

If you're refering to the SimpleImageField,its been depricated and you should use UploadField

One of the great things with SS3 is Images can be a $has_many relation, and there is Gallery module that has a sortable UploadField for images that works quite well, so it may be worth looking into upgrading your code there too.


Community Member, 4 Posts

8 January 2013 at 5:53pm

Image link