// Normally we want the overview of all registered extensions
$do = 'overview';
-$SEL = 0;
+$SEL = '0';
// Are some extensions submitted?
if (isPostRequestElementSet('sel')) {
if (isGetRequestElementSet('reg_ext')) {
// We are about to register a new extension
$do = 'register'; $ext_id = bigintval(getRequestElement('reg_ext'));
- // The ID comes from task management and it is - of course - *not* the extension's name!
+ // The id comes from task management and it is - of course - *not* the extension's name!
} elseif ((isPostRequestElementSet('change')) && ($SEL > 0) && (!isDemoModeActive())) {
// De-/activate extensions
foreach (postRequestElement('sel') as $ext_id => $active) {
// Change settings like CSS file load
if (isPostRequestElementSet(('modify'))) {
// Change entries
- $cache_update = 0;
+ $cache_update = '0';
foreach (postRequestElement('sel') as $ext_id => $sel) {
- // Secure ID
+ // Secure id
$ext_id = bigintval($ext_id);
// Change this extension?
$do = 'delete';
} elseif ((isPostRequestElementSet('remove')) && ($SEL > 0) && (!isDemoModeActive())) {
// Remove extensions from DB (you have to delete all files manually!)
- $cache_update = 0;
+ $cache_update = '0';
foreach (postRequestElement('sel') as $ext_id => $active) {
- // Secure ID number
+ // Secure id number
$ext_id = bigintval($ext_id);
// Is this extension selected and id valid?
// Free result
SQL_FREERESULT($result);
- // Is the ID number valid and the task was found?
+ // Is the id number valid and the task was found?
if (($ext_id > 0) && ($task_found == 1)) {
- // ID is valid so begin with registration, we first want to it's real name from task management (subject column)
+ // id is valid so begin with registration, we first want to it's real name from task management (subject column)
$result = SQL_QUERY_ESC("SELECT `subject` FROM `{?_MYSQL_PREFIX?}_task_system` WHERE `id`=%s LIMIT 1",
array(bigintval($ext_id)), __FILE__, __LINE__);
list($subj) = SQL_FETCHROW($result);
SQL_FREERESULT($result);
// Disable cache update by default
- $cache_update = 0;
+ $cache_update = '0';
if (!empty($subj)) {
// Extract extension's name from subject...
$ext_name = trim(substr($subj, 1, strpos($subj, ':') - 1));
// ... so we can finally register and load it in registration mode
if (registerExtension($ext_name, $ext_id)) {
// Errors?
- if (getTotalFatalErrors() == 0) {
+ if (getTotalFatalErrors() == '0') {
// Extension was found and successfully registered
loadTemplate('admin_settings_saved', false, sprintf(getMessage('ADMIN_EXTENSION_REGISTERED'), $ext_name));
// Extension was not found in task management
loadTemplate('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_ID_404'));
}
- } elseif ($task_found == 0) {
+ } elseif ($task_found == '0') {
// No longer assigned or old task
loadTemplate('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_ASSIGED'));
} else {
- // ID is invalid
+ // id is invalid
loadTemplate('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_INVALID'));
}
break;