enhance description of newsfeed-settings; ask whether to activate the newsfeed on install in case admin does not want any external requests
Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
@@ -372,7 +372,7 @@ INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES
|
||||
('dkim', 'dkim_domains', 'domains'),
|
||||
('dkim', 'dkim_dkimkeys', 'dkim-keys.conf'),
|
||||
('dkim', 'dkimrestart_command', '/etc/init.d/dkim-filter restart'),
|
||||
('admin', 'show_news_feed', '1'),
|
||||
('admin', 'show_news_feed', '0'),
|
||||
('admin', 'show_version_login', '0'),
|
||||
('admin', 'show_version_footer', '0'),
|
||||
('spf', 'use_spf', '0'),
|
||||
|
||||
@@ -160,6 +160,7 @@ class FroxlorInstall {
|
||||
$this->_getPostField('admin_user', 'admin');
|
||||
$this->_getPostField('admin_pass1');
|
||||
$this->_getPostField('admin_pass2');
|
||||
$this->_getPostField('activate_newsfeed', 1);
|
||||
$posixusername = posix_getpwuid(posix_getuid());
|
||||
$this->_getPostField('httpuser', $posixusername['name']);
|
||||
$posixgroup = posix_getgrgid(posix_getgid());
|
||||
@@ -473,6 +474,7 @@ class FroxlorInstall {
|
||||
$this->_updateSetting($upd_stmt, '/var/run/', 'phpfpm', 'fastcgi_ipcdir');
|
||||
}
|
||||
|
||||
$this->_updateSetting($upd_stmt, $this->_data['activate_newsfeed'], 'admin', 'show_news_feed');
|
||||
$this->_updateSetting($upd_stmt, dirname(dirname(dirname(__FILE__))), 'system', 'letsencryptchallengepath');
|
||||
|
||||
// insert the lastcronrun to be the installation date
|
||||
@@ -746,6 +748,8 @@ class FroxlorInstall {
|
||||
} else { $style = '';
|
||||
}
|
||||
$formdata .= $this->_getSectionItemString('admin_pass2', true, $style, 'password');
|
||||
// activate newsfeed?
|
||||
$formdata .= $this->_getSectionItemYesNo('activate_newsfeed', true);
|
||||
|
||||
/**
|
||||
* Server data
|
||||
@@ -819,10 +823,10 @@ class FroxlorInstall {
|
||||
}
|
||||
|
||||
/**
|
||||
* generate form checkbox field
|
||||
* generate form radio field for webserver-selection
|
||||
*
|
||||
* @param string $fieldname
|
||||
* @param boolean $required
|
||||
* @param boolean $checked
|
||||
* @param string $style
|
||||
*
|
||||
* @return string
|
||||
@@ -837,6 +841,25 @@ class FroxlorInstall {
|
||||
return $sectionitem;
|
||||
}
|
||||
|
||||
/**
|
||||
* generate form checkbox field
|
||||
*
|
||||
* @param string $fieldname
|
||||
* @param boolean $checked
|
||||
* @param string $style
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function _getSectionItemYesNo($fieldname = null, $checked = false, $style = "") {
|
||||
$fieldlabel = $this->_lng['install'][$fieldname];
|
||||
if ($checked) {
|
||||
$checked = 'checked="checked"';
|
||||
}
|
||||
$sectionitem = "";
|
||||
eval("\$sectionitem .= \"" . $this->_getTemplate("dataitemyesno") . "\";");
|
||||
return $sectionitem;
|
||||
}
|
||||
|
||||
/**
|
||||
* check for requirements froxlor needs
|
||||
*/
|
||||
|
||||
@@ -56,6 +56,7 @@ $lng['install']['admin_account'] = 'Administrator Account';
|
||||
$lng['install']['admin_user'] = 'Administrator Username';
|
||||
$lng['install']['admin_pass1'] = 'Administrator Password';
|
||||
$lng['install']['admin_pass2'] = 'Administrator-Password (confirm)';
|
||||
$lng['install']['activate_newsfeed'] = 'Enable the official newsfeed<br><small>(https://inside.froxlor.org/news/)</small>';
|
||||
$lng['install']['serversettings'] = 'Server settings';
|
||||
$lng['install']['servername'] = 'Server name (FQDN, no ip-address)';
|
||||
$lng['install']['serverip'] = 'Server IP';
|
||||
|
||||
@@ -56,6 +56,7 @@ $lng['install']['admin_account'] = 'Admin-Zugang';
|
||||
$lng['install']['admin_user'] = 'Administrator-Benutzername';
|
||||
$lng['install']['admin_pass1'] = 'Administrator-Passwort';
|
||||
$lng['install']['admin_pass2'] = 'Administrator-Passwort (Bestätigung)';
|
||||
$lng['install']['activate_newsfeed'] = 'Aktiviere das offizielle Newsfeed<br><small>(https://inside.froxlor.org/news/)</small>';
|
||||
$lng['install']['serversettings'] = 'Servereinstellungen';
|
||||
$lng['install']['servername'] = 'Servername (FQDN, keine IP-Adresse)';
|
||||
$lng['install']['serverip'] = 'Server-IP';
|
||||
|
||||
4
install/templates/dataitemyesno.tpl
Normal file
4
install/templates/dataitemyesno.tpl
Normal file
@@ -0,0 +1,4 @@
|
||||
<p>
|
||||
<label for="{$fieldname}" class="install-block {$style}">{$fieldlabel}:</label>
|
||||
<input type="checkbox" name="{$fieldname}" id="{$fieldname}" value="1" {$checked} />
|
||||
</p>
|
||||
@@ -40,7 +40,7 @@ if ($action == "newsfeed") {
|
||||
if (isset($_GET['role']) && $_GET['role'] == "customer") {
|
||||
$feed = Settings::Get("customer.news_feed_url");
|
||||
} else {
|
||||
$feed = "http://inside.froxlor.org/news/";
|
||||
$feed = "https://inside.froxlor.org/news/";
|
||||
}
|
||||
|
||||
if (function_exists("simplexml_load_file") == false) {
|
||||
|
||||
@@ -1762,7 +1762,7 @@ $lng['admin']['templates']['SERVER_IP'] = 'Replaces the default server ip-addres
|
||||
$lng['admin']['templates']['SERVER_PORT'] = 'Replaces the default server port';
|
||||
$lng['admin']['templates']['DOMAINNAME'] = 'Replaces the customers standard-subdomain (can be empty if none is generated)';
|
||||
$lng['admin']['show_news_feed']['title'] = 'Show news-feed on admin-dashboard';
|
||||
$lng['admin']['show_news_feed']['description'] = 'Enable this to show the official froxlor newsfeed on your dashboard and never miss important information or release-announcements.';
|
||||
$lng['admin']['show_news_feed']['description'] = 'Enable this to show the official froxlor newsfeed (https://inside.froxlor.org/news/) on your dashboard and never miss important information or release-announcements.';
|
||||
$lng['panel']['newsfeed_disabled'] = 'The newsfeed is disabled. Click the edit icon to go to the settings.';
|
||||
|
||||
// Added in Froxlor 0.9.32
|
||||
@@ -1807,7 +1807,7 @@ $lng['error']['passwordshouldnotbeusername'] = 'The password should not be the s
|
||||
// Added in Froxlor 0.9.33
|
||||
$lng['admin']['customer_show_news_feed'] = "Show newsfeed on customer-dashboard";
|
||||
$lng['admin']['customer_news_feed_url']['title'] = "Use custom RSS-feed";
|
||||
$lng['admin']['customer_news_feed_url']['description'] = "Specify a custom RSS-feed that will be shown to your customers on their dashboard.<br /><small>Leave this empty to use the official froxlor newsfeed.</small>";
|
||||
$lng['admin']['customer_news_feed_url']['description'] = "Specify a custom RSS-feed that will be shown to your customers on their dashboard.<br /><small>Leave this empty to use the official froxlor newsfeed (https://inside.froxlor.org/news/).</small>";
|
||||
$lng['serversettings']['dns_createhostnameentry'] = "Create bind-zone/config for system hostname";
|
||||
$lng['serversettings']['panel_password_alpha_lower']['title'] = 'Lowercase character';
|
||||
$lng['serversettings']['panel_password_alpha_lower']['description'] = 'Password must contain at least one lowercase letter (a-z).';
|
||||
|
||||
@@ -1488,7 +1488,7 @@ $lng['admin']['templates']['SERVER_IP'] = 'Wird mit der Standard-System-IP-Adres
|
||||
$lng['admin']['templates']['SERVER_PORT'] = 'Wird mit dem Standard-Port ersetzt';
|
||||
$lng['admin']['templates']['DOMAINNAME'] = 'Wird mit der Standardsubdomain des Kunden ersetzt (kann leer sein, wenn keine erstellt werden soll)';
|
||||
$lng['admin']['show_news_feed']['title'] = 'Zeige Newsfeed im Admin-Dashboard';
|
||||
$lng['admin']['show_news_feed']['description'] = 'Aktiviere diese Option, um das offizielle Froxlor newsfeed auf deinem Dashboard anzuzeigen und verpasse keine wichtigen Informationen oder Release-Announcements.';
|
||||
$lng['admin']['show_news_feed']['description'] = 'Aktiviere diese Option, um das offizielle Froxlor newsfeed (https://inside.froxlor.org/news/) auf deinem Dashboard anzuzeigen und verpasse keine wichtigen Informationen oder Release-Announcements.';
|
||||
$lng['panel']['newsfeed_disabled'] = 'Das Newsfeed ist deaktiviert. Klicke das Editier-Icon, um zu den Einstellungen zu gelangen.';
|
||||
|
||||
// Added in Froxlfor 0.9.32
|
||||
@@ -1533,7 +1533,7 @@ $lng['error']['passwordshouldnotbeusername'] = 'Das Passwort sollte nicht mit de
|
||||
// Added in Froxlor 0.9.33
|
||||
$lng['admin']['customer_show_news_feed'] = "Zeige Newsfeed im Kunden-Dashboard";
|
||||
$lng['admin']['customer_news_feed_url']['title'] = "Benutzerdefiniertes RSS-Feed";
|
||||
$lng['admin']['customer_news_feed_url']['description'] = "Hier kann ein eigenes RSS-Feed angegeben werden, welches den Kunden auf dem Dashboard angezeigt wird.<br /><small>Leerlassen um das offizielle Froxlor Newsfeed zu verwenden.</small>";
|
||||
$lng['admin']['customer_news_feed_url']['description'] = "Hier kann ein eigenes RSS-Feed angegeben werden, welches den Kunden auf dem Dashboard angezeigt wird.<br /><small>Leerlassen um das offizielle Froxlor Newsfeed (https://inside.froxlor.org/news/) zu verwenden.</small>";
|
||||
$lng['serversettings']['dns_createhostnameentry'] = "Erstelle bind-Zone/Konfiguration für den System-Hostnamen";
|
||||
$lng['serversettings']['panel_password_alpha_lower']['title'] = 'Kleinbuchstaben';
|
||||
$lng['serversettings']['panel_password_alpha_lower']['description'] = 'Das Passwort muss mindestens einen Kleinbuchstaben (a-z) enthalten.';
|
||||
|
||||
Reference in New Issue
Block a user