/** * Check if give path is writeable. */ function vtlib_isWriteable($path) { if (is_dir($path)) { return vtlib_isDirWriteable($path); } else { return is_writable($path); } }
vtlib_toggleModuleAccess($module_name, false); } } } // Check write permissions on the required directories $dir_notwritable = array(); if (!vtlib_isDirWriteable('test/vtlib')) { $dir_notwritable[] = 'test/vtlib'; } if (!vtlib_isDirWriteable('cron/modules')) { $dir_notwritable[] = 'cron/modules'; } if (!vtlib_isDirWriteable('modules')) { $dir_notwritable[] = 'modules'; } if (!vtlib_isDirWriteable('Smarty/templates/modules')) { $dir_notwritable[] = 'Smarty/templates/modules'; } $smarty->assign("DIR_NOTWRITABLE_LIST", $dir_notwritable); // END $smarty->assign("TOGGLE_MODINFO", vtlib_getToggleModuleInfo()); $smarty->assign("TOGGLE_LANGINFO", vtlib_getToggleLanguageInfo()); if ($_REQUEST['mode'] != '') { $mode = $_REQUEST['mode']; } $smarty->assign("MODE", vtlib_purify($mode)); if ($_REQUEST['ajax'] != 'true') { $smarty->display('Settings/ModuleManager/ModuleManager.tpl'); } else { $smarty->display('Settings/ModuleManager/ModuleManagerAjax.tpl'); }