more styling for disabled options
new "Developer" tab (by default all options are disabled, users can't modify them) fixed UserprefsDisallow export in setup script
This commit is contained in:
@@ -26,6 +26,19 @@ require_once './libraries/user_preferences.inc.php';
|
||||
|
||||
$form_display = new FormDisplay();
|
||||
foreach ($forms[$form_param] as $form_name => $form) {
|
||||
// skip Developer form if no setting is available
|
||||
if ($form_name == 'Developer') {
|
||||
$show = false;
|
||||
foreach ($form as $field_name) {
|
||||
if (array_search($field_name, $GLOBALS['cfg']['UserprefsDisallow']) === false) {
|
||||
$show = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!$show) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
$form_display->registerForm($form_name, $form);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user