Created
September 28, 2012 18:41
-
-
Save bjornbjorn/3801466 to your computer and use it in GitHub Desktop.
@focuslabllc Master Config file upload directory paths
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$env_config['upload_preferences'] = array( | |
1 => array( | |
'name' => 'Uploads', | |
'server_path' => APPPATH."..\\..\\webroot\\uploads\\", | |
'url' => $env_config['base_url'].'uploads/' | |
), | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$env_config['upload_preferences'] = array(
1 => array(
'name' => 'Default Uploads',
'server_path' => $images_path . '/uploads/',
'url' => $images_url . '/uploads/'
),
2 => array(
'name' => 'Second Folder',
'server_path' => $images_path . '/another_one/',
'url' => $images_url . '/another_one/'
),
2 => array(
'name' => 'Third Folder',
'server_path' => $images_path . '/third_one/',
'url' => $images_url . '/third_one/'
)
);
You also need to create the actual folder itself in the location you set. If you add a third item don't forget to add a trailing comma to the end of the second item. The numbers ie. 1,2,3 should coincide with the ID of the file upload preferences in the CP so, theoretically they could be 3, 4 and 5 or anything for that matter as they are dependent on the ID as mentioned. I recommend adding a trailing slash / to the end of the server_path, something which wasn't done in the example of the master config.