Hi blair,
any info on why it didn't make it into 2.3.3 or how we can make it work in 2.3.3? which files to patch / replace?
thanks,
wmk
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Hi blair,
any info on why it didn't make it into 2.3.3 or how we can make it work in 2.3.3? which files to patch / replace?
thanks,
wmk
Hi wmk,
Sounds like the fix will be included in 2.4.0.
I have asked for a patch from Silverstripe as this is something we really need to work. Will let you know once I hear from them.
Blair.
I wrote a SS2.3.x-module with a temporate fix that can be downloaded here.
Of course you have to do some rewriting as soon as you start updating your productionsites.
Hi, if you have a look at the changelog from 2.3.4 you will not find the bugfix for the image-upload-folder-problem. Could anybody publish the bugfix for those who need it importantly?
Carsten...
In 2.4 , this problem has been fixed.
BUT, it would be _really_ nice if you could tell the image-field "from the file store" dropdown to go to a specific folder as well.. (usecase : client uploads a shitload of assets by FTP , reloads the assets , and needs to link those images to dataobjects or pages)..
Is this possible ?
Hi Fuzz10,
I actually had a play around with this and have a slightly hacked custom field working with this option. Basically there is no way to do this with the standard file fields, however the treeDropdownField which is used to select the folder does have a argument to define the starting ID for the tree, so basically I have created a custom field with a 7th argument which is the name of the folder you want to start with. However, it does mean that you can't make your way back above this folder, so it's not particularly flexible, though that could be a good thing depending on the use case.
Anyway here is the code for the CustomFileField: http://pastie.org/930505
To use it simply supply the folder you want to set as the selected one as the final argument like so:
new CustomFileField('FieldName', 'Title', Null, Null, Null, 'UploadFolder', 'SelectedFolder');
Note, if the folder does not exist it will default to root.
Also I did this pretty quickly so it might not be totally sound, and have only tested this on 2.4 RC1.
Let me know if works for you :)
Aram
www.SSBits.com - SilverStripe tutorials, tips and other bits
Aram,
Thanks a bundle !! I'll play around with this over the next weekend !!!
I think this would be a very nice addition to the core CMS , no ?
Yea would definately be useful as a core feature and seems like all the basics are there to implement it, though not sure my code would be good enough! lol
Aram
www.SSBits.com - SilverStripe tutorials, tips and other bits.