no need to press save twice

pull/2718/head
HB9HIL 2023-11-22 15:07:16 +01:00
rodzic 90783ce553
commit dbcc5ed91f
2 zmienionych plików z 6 dodań i 2 usunięć

Wyświetl plik

@ -272,7 +272,11 @@ class Options extends CI_Controller {
$smtpEncryptionupdate = $this->optionslib->update('smtpEncryption', $this->input->post('smtpEncryption'), 'yes');
// Update email sender name within the options system
$emailSenderNameupdate = $this->optionslib->update('emailSenderName', $this->input->post('emailSenderName'), 'yes');
$emailSenderName_value = $this->input->post('emailSenderName');
if (empty($emailSenderName_value)) {
$emailSenderName_value = 'Cloudlog';
}
$emailSenderNameupdate = $this->optionslib->update('emailSenderName', $emailSenderName_value, 'yes');
// Update email address choice within the options system
$emailAddressupdate = $this->optionslib->update('emailAddress', $this->input->post('emailAddress'), 'yes');

Wyświetl plik

@ -63,7 +63,7 @@
<div class="form-group row">
<label for="emailSenderName" class="col-sm-2 col-form-label"><?php echo lang('options_email_sender_name'); ?></label>
<div class="col-sm-10">
<input type="text" name="emailSenderName" class="form-control" id="emailSenderName" value="<?php echo ($this->optionslib->get_option('emailSenderName') == "" ? 'Cloudlog' : $this->optionslib->get_option('emailSenderName'));?>">
<input type="text" name="emailSenderName" class="form-control" id="emailSenderName" value="<?php if($this->optionslib->get_option('emailSenderName') != "") { echo $this->optionslib->get_option('emailSenderName'); } ?>">
<small class="form-text text-muted"><?php echo lang('options_email_sender_name_hint'); ?></small>
</div>
</div>