AbleCommerce Forums
»
AbleCommerce
»
AbleCommerce 9 Bug Reports
»
File upload- no restrictions as to file type 9.0.7
Rank: Advanced Member
Groups: Developers
Joined: 11/7/2018(UTC) Posts: 303
Thanks: 21 times Was thanked: 5 time(s) in 5 post(s)
|
Go to Catalog-->Images Do not have any restrictions set on file types under security Click Upload... either image or file Click to upload in dropzone. Window opens with *.Any in the file type dropdown No files show, only folders Change to All Files (*) Click on a file to upload Nothing happens
This works OK if you have restricted the file types under Security
|
|
|
|
Rank: Advanced Member
Groups: Administrators, Developers, Registered, HelpDesk, Authorized User, Admin, System Joined: 10/11/2018(UTC) Posts: 110
Thanks: 19 times Was thanked: 18 time(s) in 18 post(s)
|
I am able to reproduce the issue. Although, we are showing the validation message "Only images/files are accepted" but I think we don't need to apply any restriction when Any is selected as a valid image/file type or have to show the related message in this case. Any ways, I have this registered as a bug to be looked into. If you want to remove the restriction when no file type is selected (Any), you can apply the following quick fix: Open the file /Areas/Admin/Controllers/AssetsController.cs and locate the following line inside ImageUpload/FileUpload post actions: Code:FileHelper.IsExtensionValid(safeFileName, AbleContext.Current.Store.Settings.FileExt_Assets))
and replace with Code:FileHelper.IsExtensionValid(safeFileName, AbleContext.Current.Store.Settings.FileExt_Assets) || imageModel.ValidFiles.Equals("Any"))
Thank you!
|
1 user thanked nadeem for this useful post.
|
|
|
AbleCommerce Forums
»
AbleCommerce
»
AbleCommerce 9 Bug Reports
»
File upload- no restrictions as to file type 9.0.7
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.
Important Information:
The AbleCommerce Forums uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
More Details
Close