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.

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

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

ImageGallery uploads to wrong folder on edit then when record saved image disappears


Reply


5 Posts   1015 Views

Avatar
CodeGuerrilla

Community Member, 105 Posts

9 April 2010 at 6:34pm

Edited: 09/04/2010 7:09pm

Am using the latest versions of DOM, ImageGallery and SWFUpload for one of our client sites was working fine until they decided to edit some gallery items and replace the image seems to work but when you save the database record the image disappears.

After a lot of investigation we found that when adding images the images are saved in:

assets/image-gallery/<page-name>/<album_name>

When editing an existing image selecting an existing image works, but when uploading a new one through the FileIFrameField it uploads the image to:

assets/Uploads

When you save the record it sets it back to:

assets/image-gallery/<page-name>/<album_name>

Has anyone else experienced this can this be related to the infamous bug:

[url]http://www.silverstripe.org/customising-the-cms/show/276189#post276189[/url]

[url]http://www.silverstripe.org/customising-the-cms/show/275888#post275888[/url]

[url]http://www.silverstripe.org/archive/show/60837#post60837[/url]

[url]http://www.silverstripe.org/archive/show/64965#post64965[/url]

I know there are way more posts on this subject if you find any please post here.

Avatar
creatormarius

Community Member, 11 Posts

19 May 2010 at 6:55pm

Same here. Any luck patching this. I'm digging through the code now....

Avatar
CodeGuerrilla

Community Member, 105 Posts

19 May 2010 at 7:26pm

No luck on this one, was pretty reluctant to debug the modules really haven't had the time, we convinced the client to live with it just don't edit an existing image by uploading over top of it :)

Avatar
UncleCheese

Forum Moderator, 4096 Posts

20 May 2010 at 1:53am

Yeah, that's a major drag. AFAIK, the ImageField doesn't give you control over where a file saves the way that a DOM does. I'm not sure if that's been updated in 2.4, but it would be really nice to have that option.

Avatar
creatormarius

Community Member, 11 Posts

23 May 2010 at 5:46pm

There's a way...

either hack core (for now....)

or extend Image_Uploader controller.

see post : [url]http://www.silverstripe.org/all-other-modules/show/266319[/url]