Skip to content
Snippets Groups Projects
Commit a1c32c4a authored by Tim Steiner's avatar Tim Steiner
Browse files

Adding the ability to set the default temp dir for new UNL profile sites via an ini file.

git-svn-id: file:///tmp/wdn_thm_drupal/branches/drupal-7.x@167 20a16fea-79d4-4915-8869-1ea9d5ebf173
parent f8a441ce
No related branches found
No related tags found
No related merge requests found
[defaults]
temp_dir = "/tmp/"
......@@ -10,6 +10,13 @@ function unl_profile_install()
// Start out by calling the standard profile's setup.
require_once dirname(__FILE__) . '/../standard/standard.install';
standard_install();
// Load the ini file (if it exists)
$ini_file = dirname(__FILE__) . '/unl_profile.ini';
$ini_settings = array();
if (file_exists($ini_file)) {
$ini_settings = parse_ini_file($ini_file);
}
// Enable some standard blocks.
$values = array(
......@@ -44,6 +51,10 @@ function unl_profile_install()
theme_enable(array('unl_wdn'));
variable_set('theme_default', 'unl_wdn');
if (isset($ini_settings['temp_dir'])) {
variable_set('file_temporary_path', $ini_settings['temp_dir']);
}
//TODO: IMCE setup (currently cannot be shared between sites)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment