function HTTPS_PORT() { $httpd = new httpd(); $users = new usersMenus(); $page = CurrentPageName(); $use_apache = null; $sock = new sockets(); $tpl = new templates(); $LighttpdUserAndGroup = $sock->GET_INFO("LighttpdUserAndGroup"); $LighttpdArticaDisabled = $sock->GET_INFO("LighttpdArticaDisabled"); $LighttpdArticaDisableSSLv2 = $sock->GET_INFO("LighttpdArticaDisableSSLv2"); $ConfirmDisableArticaWebConsole = $tpl->javascript_parse_text("{ConfirmDisableArticaWebConsole}"); if ($LighttpdUserAndGroup == null) { $LighttpdUserAndGroup = "www-data:www-data"; } $ArticaHttpsPort = $sock->GET_INFO("ArticaHttpsPort"); $ArticaHttpUseSSL = $sock->GET_INFO("ArticaHttpUseSSL"); if (!is_numeric($ArticaHttpUseSSL)) { $ArticaHttpUseSSL = 1; } if (!is_numeric($LighttpdArticaDisabled)) { $LighttpdArticaDisabled = 0; } if (!is_numeric($LighttpdArticaDisableSSLv2)) { $LighttpdArticaDisableSSLv2 = 0; } if ($ArticaHttpsPort == null) { $ArticaHttpsPort = "9000"; } $lighttp_processes = "<tr>\n\t\t\t<td nowrap nowrap class=legend>{processes}:</strong></td>\n\t\t\t<td><input type='button' value='{advanced_settings} »' OnClick=\"javascript:YahooWin3(440,'{$page}?advlighttp=yes');\"></td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td nowrap nowrap class=legend>{LighttpdUseLdap}:</strong></td>\n\t\t\t<td>" . Field_numeric_checkbox_img('LighttpdUseLdap', $httpd->LighttpdUseLdap, '{LighttpdUseLdap_text}') . "</td>\n\t\t</tr>\t"; if ($users->lighttpd_installed) { $use_apache = "<tr>\n\t\t\t<td nowrap class=legend>{disable_webconsole_engine}:</strong></td>\n\t\t\t<td>" . Field_checkbox('LighttpdArticaDisabled', 1, $LighttpdArticaDisabled, "LighttpdArticaDisabledCheck()") . "</td>\n\t\t</tr>"; $lighttp_processes = "<input type='hidden' id='LighttpdUseLdap' value=',{$httpd->LighttpdUseLdap}'>"; } $lighttpd_usenossl = "\n\t\t<tr>\n\t\t\t<td nowrap nowrap class=legend>{ssl}:</strong></td>\n\t\t\t<td>" . Field_checkbox("ArticaHttpUseSSL", 1, $ArticaHttpUseSSL, "WebArticaCheck()") . "</td>\n\t\t</tr>\t\n\t\t<tr>\n\t\t\t<td nowrap nowrap class=legend>{disableSSLv2}:</strong></td>\n\t\t\t<td>" . Field_checkbox("LighttpdArticaDisableSSLv2", 1, $LighttpdArticaDisableSSLv2, "disableSSLv2Check()") . "</td>\n\t\t</tr>\t\n\t"; if ($use_apache == null) { $use_apache = "<input type='hidden' name='ApacheArticaEnabled' value='0'>"; } $html = "\n\t<input type='hidden' id='interface_restarted' value='{interface_restarted}'>\n\t<form name='FFM109'>\n\t<input type='hidden' name='http_settings' value='yes'>\n\t<script>\n\t\tfunction LighttpdArticaDisabledCheck(){\n\t\t\tvar XHR = new XHRConnection();\n\t\t\tif(document.getElementById('LighttpdArticaDisabled').checked){\n\t\t\t\tif(!confirm('{$ConfirmDisableArticaWebConsole}')){return;}\n\t\t\t\tXHR.appendData('LighttpdArticaDisabled',1);\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\tXHR.appendData('LighttpdArticaDisabled',0);\n\t\t\t}\n\t\t\tLighttpdArticaDisabledcheck();\n\t\t\tXHR.sendAndLoad('{$page}', 'GET');\n\t\t\n\t\t}\n\t\t\n\t\tfunction disableSSLv2Check(){\n\t\t\tvar XHR = new XHRConnection();\n\t\t\tif(document.getElementById('LighttpdArticaDisableSSLv2').checked){\n\t\t\t\tXHR.appendData('LighttpdArticaDisableSSLv2',1);\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\tXHR.appendData('LighttpdArticaDisableSSLv2',0);\n\t\t\t}\n\t\t\tXHR.sendAndLoad('{$page}', 'POST');\n\t\t\n\t\t}\t\t\n\t\t\n\t\t\n\t\t\n\t\tfunction WebArticaCheck(){\n\t\t\tdocument.getElementById('LighttpdArticaDisableSSLv2').disabled=true;\n\t\t\tif(document.getElementById('ArticaHttpUseSSL')){\n\t\t\t\tif(document.getElementById('ArticaHttpUseSSL').checked){\n\t\t\t\t\tdocument.getElementById('LighttpdArticaDisableSSLv2').disabled=false;\t\n\t\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t}\n\t\t\n\t\tfunction LighttpdArticaDisabledcheck(){\n\t\t\tif(!document.getElementById('LighttpdArticaDisabled')){return;}\n\t\t\tdocument.getElementById('LighttpdArticaDisableSSLv2').disabled=true;\n\t\t\tdocument.getElementById('ArticaHttpUseSSL').disabled=true;\n\t\t\tdocument.getElementById('https_port').disabled=true;\n\t\t\tdocument.getElementById('LighttpdUserAndGroup').disabled=true;\n\t\t\tif(!document.getElementById('LighttpdArticaDisabled').checked){\n\t\t\t\tdocument.getElementById('LighttpdArticaDisableSSLv2').disabled=false;\n\t\t\t\tdocument.getElementById('ArticaHttpUseSSL').disabled=false;\n\t\t\t\tdocument.getElementById('https_port').disabled=false;\n\t\t\t\tdocument.getElementById('LighttpdUserAndGroup').disabled=false;\t\t\n\t\t\t}\n\t\t\n\t\t}\n\t\t\n\t\t\n\tWebArticaCheck();\t\n\tLighttpdArticaDisabledcheck();\n\t</script>\n\t\n\t<H5>{web_interface_settings}</H5>\n\t"; if ($users->lighttpd_installed) { $lighttpd = "\n\t\t{$use_apache}\n\t\t{$lighttp_processes}\n\t\t{$lighttpd_usenossl}\n\t\t\t\t\t\t\n\t\t"; } else { $html = $html . "<input type='hidden' name='ApacheArticaEnabled' value='1'>"; } $html = $html . "\n<table style='width:100%'>\n<tr>\n\t<td valign='top'>\n\t" . Paragraphe("64-settings.png", "{advanced_options}", "{php_advanced_options_text}", "javascript:Loadjs('phpconfig.php')") . "</td>\n\t<td valign='top'>\n\t\t\t<table style='width:100%' class=form>\n\t\t\t{$lighttpd}\n\t\t\t<tr>\n\t\t\t\t<td nowrap class=legend>{listen_port}:</strong></td>\n\t\t\t\t<td>" . Field_text('https_port', trim($ArticaHttpsPort), 'width:100px;font-size:13px;padding:3px') . "</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td nowrap class=legend>{username}:</strong></td>\n\t\t\t\t<td>" . Field_text('LighttpdUserAndGroup', trim($LighttpdUserAndGroup), 'width:130px;font-size:13px;padding:3px') . "</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td colspan=2 align='right'>\n\t\t\t\t\t<span style='padding-top:3px'><a href='javascript:blur();' OnClick=\"javascript:Loadjs('phpconfig.php');\">{advanced_options}</a></span>\n\t\t\t\t</td>\n\t\t\t</tr>\t\t\t\n\t\t\t<tr>\n\t\t\t\t<td colspan=2 align='right'>\n\t\t\t\t\t<hr>\n\t\t\t\t\t" . button("{apply}", "HTTPS_PORT()") . "\n\t\t\t\t\t\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\n\t\t</table>\n\t</td>\n</tR>\n</table>\n</form>\n" . TIME_ZONE_SETTINGS(); return $html; }
function HTTPS_PORT() { $httpd = new httpd(); $users = new usersMenus(); $page = CurrentPageName(); $use_apache = null; $sock = new sockets(); $LighttpdUserAndGroup = $sock->GET_INFO("LighttpdUserAndGroup"); if ($LighttpdUserAndGroup == null) { $LighttpdUserAndGroup = "www-data:www-data"; } $ArticaHttpsPort = $sock->GET_INFO("ArticaHttpsPort"); if ($ArticaHttpsPort == null) { $ArticaHttpsPort = "9000"; } $lighttp_processes = "<tr>\n\t\t\t<td nowrap nowrap class=legend>{processes}:</strong></td>\n\t\t\t<td><input type='button' value='{advanced_settings} »' OnClick=\"javascript:YahooWin3(440,'{$page}?advlighttp=yes');\"></td>\n\t\t</tr><tr>\n\t\t\t<td nowrap nowrap class=legend>{LighttpdUseLdap}:</strong></td>\n\t\t\t<td>" . Field_numeric_checkbox_img('LighttpdUseLdap', $httpd->LighttpdUseLdap, '{LighttpdUseLdap_text}') . "</td>\n\t\t</tr>\t"; if ($users->lighttpd_installed) { if ($users->APACHE_INSTALLED) { $use_apache = "<tr>\n\t\t\t<td nowrap class=legend>{use_apache}:</strong></td>\n\t\t\t<td>" . Field_numeric_checkbox_img('ApacheArticaEnabled', $httpd->ApacheArticaEnabled, '{use_apache_text}') . "</td>\n\t\t</tr>"; $lighttp_processes = "<input type='hidden' id='LighttpdUseLdap' value=',{$httpd->LighttpdUseLdap}'>"; } } if ($use_apache == null) { $use_apache = "<input type='hidden' name='ApacheArticaEnabled' value='0'>"; } $html = "\n\t<input type='hidden' id='interface_restarted' value='{interface_restarted}'>\n\t<form name='FFM109'>\n\t<input type='hidden' name='http_settings' value='yes'>\n\t\n\t<H5>{web_interface_settings}</H5>\n\t"; if ($users->lighttpd_installed) { $lighttpd = "\n\t\t{$use_apache}\n\t\t{$lighttp_processes}\n\t\t\t\t\t\t\n\t\t"; } else { $html = $html . "<input type='hidden' name='ApacheArticaEnabled' value='1'>"; } $html = $html . "\n<table style='width:100%'>\n<tr>\n\t<td valign='top'>\n\t" . Paragraphe("64-settings.png", "{advanced_options}", "{php_advanced_options_text}", "javascript:Loadjs('phpconfig.php')") . "</td>\n\t<td valign='top'>\n\t\t\t<table style='width:100%'>\n\t\t\t{$lighttpd}\n\t\t\t<tr>\n\t\t\t\t<td nowrap class=legend>{https_port}:</strong></td>\n\t\t\t\t<td>" . Field_text('https_port', trim($ArticaHttpsPort), 'width:100px') . "</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td nowrap class=legend>{username}:</strong></td>\n\t\t\t\t<td>" . Field_text('LighttpdUserAndGroup', trim($LighttpdUserAndGroup), 'width:120px') . "</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td colspan=2 align='right'>\n\t\t\t\t\t<span style='padding-top:3px'><a href='#' OnClick=\"javascript:Loadjs('phpconfig.php');\">{advanced_options}</a></span>\n\t\t\t\t</td>\n\t\t\t</tr>\t\t\t\n\t\t\t<tr>\n\t\t\t\t<td colspan=2 align='right'>\n\t\t\t\t\t<hr>\n\t\t\t\t\t" . button("{apply}", "HTTPS_PORT()") . "\n\t\t\t\t\t\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\n\t\t</table>\n\t</td>\n</tR>\n</table>\n</form>\n" . TIME_ZONE_SETTINGS(); return $html; }