Added an option to the User Interface page to always put the hostname before the page title.
---- Changes since 1.510 ----
Strong PCI-compliant ciphers can now be selected on the SSL Encryption page.
+---- Changes since 1.540 ----
+Added the Sending Email page which controls how Webmin itself sends messages.
log_deletecache=Deleted $1 URLs from cache
log_clearcache=Cleared all URLs from cache
log_lock=Changed file locking
+log_sendmail=Changed mail sending options
themes_title=Webmin Themes
themes_desc=Themes control the appearance of the Webmin user interface, including icons, colours, backgrounds and the layout of pages. The selection box below can be used to choose one of the themes installed on your system.
sendmail_from=From address for email from Webmin
sendmail_fromdef=Default ($1)
sendmail_fromaddr=Address
+sendmail_err=Failed to save mail sending options
+sendmail_esmtp=Missing or un-resolvable SMTP server hostname
+sendmail_elogin=Missing SMTP server login
+sendmail_efrom=Missing or incorrectly formatted from address
__norefs=1
--- /dev/null
+#!/usr/local/bin/perl
+# Save mail server settings
+
+require './webmin-lib.pl';
+&ReadParse();
+&error_setup($text{'sendmail_err'});
+&foreign_require("mailboxes");
+&lock_file($mailboxes::module_config_file);
+%mconfig = &foreign_config("mailboxes");
+
+# Save smtp server
+if ($in{'mode'} == 0) {
+ delete($mconfig{'send_mode'});
+ }
+elsif ($in{'mode'} == 1) {
+ $mconfig{'send_mode'} = '127.0.0.1';
+ }
+else {
+ &to_ipaddress($in{'smtp'}) && &to_ip6address($in{'smtp'}) ||
+ &error($text{'sendmail_esmtp'});
+ $mconfig{'send_mode'} = $in{'smtp'};
+ }
+
+# Save login and password
+if ($in{'login_def'}) {
+ delete($mconfig{'smtp_user'});
+ delete($mconfig{'smtp_pass'});
+ }
+else {
+ $in{'login_user'} =~ /^\S+$/ || &error($text{'sendmail_elogin'});
+ $mconfig{'smtp_user'} = $in{'login_user'};
+ $mconfig{'smtp_pass'} = $in{'login_pass'};
+ }
+
+# Save auth method
+$mconfig{'smtp_auth'} = $in{'auth'};
+
+# Save from address
+if ($in{'from_def'}) {
+ delete($mconfig{'webmin_addr'});
+ }
+else {
+ $in{'from'} =~ /^\S+\@\S+$/ || &error($text{'sendmail_efrom'});
+ $mconfig{'webmin_addr'} = $in{'from'};
+ }
+
+&save_module_config(\%mconfig, "mailboxes");
+&unlock_file($mailboxes::module_config_file);
+&webmin_log("sendmail");
+&redirect("");
+