Hi.
I need to force all uploads into "content/uploads/$FileType" (such as content/uploads/Image), but I need to set the Browse Server directory to just "content/". Is this possible? It seems that whatever I change 'UserFilesPath' to, the uploads go to that same folder. The code below functions by showing the Browse Server view of "content/" and all images and files also go to this folder.
Your help is much appreciated.
I need to force all uploads into "content/uploads/$FileType" (such as content/uploads/Image), but I need to set the Browse Server directory to just "content/". Is this possible? It seems that whatever I change 'UserFilesPath' to, the uploads go to that same folder. The code below functions by showing the Browse Server view of "content/" and all images and files also go to this folder.
$Config['AllowedExtensions']['File'] = array('7z', 'aiff', 'asf', 'avi', 'bmp', 'csv', 'doc', 'fla', 'flv', 'gif', 'gz', 'gzip', 'jpeg', 'jpg', 'mid', 'mov', 'mp3', 'mp4', 'mpc', 'mpeg', 'mpg', 'ods', 'odt', 'pdf', 'png', 'ppt', 'pxd', 'qt', 'ram', 'rar', 'rm', 'rmi', 'rmvb', 'rtf', 'sdc', 'sitd', 'swf', 'sxc', 'sxw', 'tar', 'tgz', 'tif', 'tiff', 'txt', 'vsd', 'wav', 'wma', 'wmv', 'xls', 'xml', 'zip') ; $Config['DeniedExtensions']['File'] = array() ; $Config['FileTypesPath']['File'] = $Config['UserFilesPath']; $Config['FileTypesAbsolutePath']['File']= ($Config['UserFilesAbsolutePath'] == '') ? '' : $Config['UserFilesAbsolutePath'].'file/' ; // SHOULD FORCE QUICK UPLOADS OF FILES INTO FILE FOLDER $Config['QuickUploadPath']['File'] = $Config['FileTypesPath']['File'] ; $Config['QuickUploadAbsolutePath']['File']= $Config['FileTypesAbsolutePath']['File'] ; $Config['AllowedExtensions']['Image'] = array('bmp','gif','jpeg','jpg','png') ; $Config['DeniedExtensions']['Image'] = array() ; $Config['FileTypesPath']['Image'] = $Config['UserFilesPath']; // GOES DIRECTLY TO /content $Config['FileTypesAbsolutePath']['Image']= ($Config['UserFilesAbsolutePath'] == '') ? '' : $Config['UserFilesAbsolutePath']; // SHOULD FORCE QUICK UPLOADS OF IMAGES INTO IMAGE FOLDER $Config['QuickUploadPath']['Image'] = $Config['FileTypesPath']['Image'] ; $Config['QuickUploadAbsolutePath']['Image'] = $Config['FileTypesAbsolutePath']['Image'] ;
Your help is much appreciated.
Re: make the uploads directory different than the browse server
Thanks