diff options
| author | winter | 2025-01-19 14:54:24 +0000 |
|---|---|---|
| committer | winter | 2025-01-19 14:54:24 +0000 |
| commit | 3fe0b3e7938bdb3781fec13784c0b7f943a899c0 (patch) | |
| tree | d0a3e73b00da531694b7f61fc7c1a1c2643862c9 | |
| parent | 2de5125d750a24d85797c5c7bb15fefdc0206511 (diff) | |
fix boolean settings having the wrong default value
| -rw-r--r-- | settings.global.ini | 7 | ||||
| -rw-r--r-- | templates/settings_field.php | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/settings.global.ini b/settings.global.ini index 79699d1..dbad00e 100644 --- a/settings.global.ini +++ b/settings.global.ini @@ -1,3 +1,6 @@ +# please put double quotes around everything. php does weird things to unquoted +# ini values sometimes and it's not worth the debugging headache + [instance.name] name = "Instance name" description = "Shown in the page header and instance information" @@ -11,5 +14,5 @@ default = "A Digitigrade instance" [instance.openRegistrations] name = "Open registrations" description = "Allow new users to sign up?" -default = false -type = boolean +default = "false" +type = "boolean" diff --git a/templates/settings_field.php b/templates/settings_field.php index 15b6c71..c0f0f7d 100644 --- a/templates/settings_field.php +++ b/templates/settings_field.php @@ -17,7 +17,7 @@ $fieldName = str_replace('.', '<DOT>', $key); <?php if ($inputType == 'select'): ?> - <select id="<?= $id ?>" name="<?= $fieldName ?>"> + <select id="<?= $id ?>" name="<?= $fieldName ?>" autocomplete="off"> <?php foreach ($options as $o): ?> <option <?= $value == $o ? 'selected' : '' ?>><?= $o ?></option> <?php endforeach; ?> |
