23355 Posts in 17702 Topics by 2862 members
|Go to End|
14 January 2011 at 4:19pm
I want to allow certain registered users the ability to upload images from the front-end of SilverStripe as well as browse the file store for images.
How can I pre-populate the ImageField with the image with an ID of 5? This does NOT work:
new ImageField('TeaserImage', 'Teaser Image',5),
I get this message: "Images can be attached once you have saved the record for the first time."
I cannot use SimpleImageField because I want users to be able to browse the file store as well as upload images.
19 January 2011 at 5:13pm Last edited: 19 January 2011 5:14pm
My advice would be to install Uploadify and use its ImageUploadField. It includes tabs to either upload new or select existing from file store.
|Go to Top|