Commit fc5bf856 authored by Kristina Hoeppner's avatar Kristina Hoeppner
Browse files

Default account options: Implement switchboxes (Bug 1431569)



Change from checkboxes to switchboxes. Affected are:
- /admin/users/add.php
- /admin/users/uploadcsv.php
- /account/index.php

Change-Id: I0c1844f14b77b564ce2e99161552df1b8764041a
Signed-off-by: Kristina Hoeppner's avatarKristina D.C. Hoeppner <kristina@catalyst.net.nz>
parent 586fdcd6
......@@ -53,7 +53,7 @@ $string['tagssideblockmaxtags'] = 'Maximum tags in cloud';
$string['tagssideblockmaxtagsdescription'] = 'Maximum number of tags to display in your tag cloud';
$string['enablemultipleblogs1'] = 'Multiple journals';
$string['enablemultipleblogsdescription'] = 'By default, you have one journal. If you would like to keep more than one journal, check this option.';
$string['enablemultipleblogsdescription1'] = 'By default, you have one journal. If you would like to keep more than one journal, turn this option on.';
$string['hiderealname'] = 'Hide real name';
$string['hiderealnamedescription'] = 'Check this box if you have set a display name and do not want other users to be able to find you by your real name in user searches.';
......@@ -83,7 +83,7 @@ $string['deleteaccountdescription'] = 'If you delete your account, all your con
$string['accountdeleted'] = 'Your account has been deleted.';
$string['resizeonuploaduserdefault1'] = 'Resize large images on upload';
$string['resizeonuploaduserdefaultdescription1'] = 'If checked, the option "Automatic resizing of images" will be enabled by default, and images larger than the maximum dimensions will be resized when they are uploaded. You can disable this default setting for each image upload individually.';
$string['resizeonuploaduserdefaultdescription2'] = '"Automatic resizing of images" is enabled by default. Images larger than the maximum dimensions will be resized when they are uploaded. You can disable this default setting for each image upload individually.';
$string['devicedetection'] = 'Device detection';
$string['devicedetectiondescription'] = 'Enable mobile device detection when browsing this site.';
......@@ -234,7 +234,7 @@ function general_account_prefs_form_elements($prefs) {
'help' => true
);
$elements['wysiwyg'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'defaultvalue' => (get_config('wysiwyg')) ? get_config('wysiwyg') == 'enable' : $prefs->wysiwyg,
'title' => get_string('wysiwygdescr', 'account'),
'help' => true,
......@@ -252,7 +252,7 @@ function general_account_prefs_form_elements($prefs) {
}
}
$elements['maildisabled'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'defaultvalue' => $prefs->maildisabled,
'title' => get_string('disableemail', 'account'),
'help' => true,
......@@ -337,16 +337,16 @@ function general_account_prefs_form_elements($prefs) {
);
$elements['addremovecolumns'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'defaultvalue' => $prefs->addremovecolumns,
'title' => get_string('showviewcolumns', 'account'),
'help' => 'true'
);
// TODO: add a way for plugins (like blog!) to have account preferences
$elements['multipleblogs'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'title'=> get_string('enablemultipleblogs1' ,'account'),
'description' => get_string('enablemultipleblogsdescription', 'account'),
'description' => get_string('enablemultipleblogsdescription1', 'account'),
'defaultvalue' => $prefs->multipleblogs,
);
if (get_config('showtagssideblock')) {
......@@ -379,7 +379,7 @@ function general_account_prefs_form_elements($prefs) {
);
if (get_config('userscanhiderealnames')) {
$elements['hiderealname'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'title' => get_string('hiderealname', 'account'),
'description' => get_string('hiderealnamedescription', 'account'),
'defaultvalue' => $prefs->hiderealname,
......@@ -387,7 +387,7 @@ function general_account_prefs_form_elements($prefs) {
}
if (get_config('homepageinfo')) {
$elements['showhomeinfo'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'defaultvalue' => $prefs->showhomeinfo,
'title' => get_string('showhomeinfo2', 'account'),
'description' => get_string('showhomeinfodescription1', 'account', hsc(get_config('sitename'))),
......@@ -396,7 +396,7 @@ function general_account_prefs_form_elements($prefs) {
}
if (get_config('showprogressbar')) {
$elements['showprogressbar'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'defaultvalue' => $prefs->showprogressbar,
'title' => get_string('showprogressbar', 'account'),
'description' => get_string('showprogressbardescription', 'account', hsc(get_config('sitename'))),
......@@ -416,16 +416,16 @@ function general_account_prefs_form_elements($prefs) {
}
if (get_config_plugin('artefact', 'file', 'resizeonuploadenable')) {
$elements['resizeonuploaduserdefault'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'title' => get_string('resizeonuploaduserdefault1', 'account'),
'description' => get_string('resizeonuploaduserdefaultdescription1', 'account'),
'description' => get_string('resizeonuploaduserdefaultdescription2', 'account'),
'defaultvalue' => $prefs->resizeonuploaduserdefault,
);
}
if (get_config('userscandisabledevicedetection')) {
$elements['devicedetection'] = array(
'type' => 'checkbox',
'type' => 'switchbox',
'title' => get_string('devicedetection', 'account'),
'description' => get_string('devicedetectiondescription', 'account'),
'defaultvalue' => $prefs->devicedetection,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment