1
0
mirror of https://github.com/billz/raspap-webgui.git synced 2023-10-10 13:37:24 +02:00

Processed with phpcs/phpcbf

This commit is contained in:
billz 2020-02-03 10:13:57 +00:00
parent 78fa4c2c9b
commit 5ff1e85274

View File

@ -1,7 +1,7 @@
<?php <?php
/** /**
* Raspbian WiFi Configuration Portal * Raspbian WiFi Configuration Portal (RaspAP)
* *
* Enables use of simple web interface rather than SSH to control wifi and hostapd on the Raspberry Pi. * Enables use of simple web interface rather than SSH to control wifi and hostapd on the Raspberry Pi.
* Recommended distribution is Raspbian Buster Lite. Specific instructions to install the supported software are * Recommended distribution is Raspbian Buster Lite. Specific instructions to install the supported software are
@ -219,51 +219,51 @@ if ($_COOKIE['sidebarToggled'] == 'true' ) {
<!-- Begin Page Content --> <!-- Begin Page Content -->
<div class="container-fluid"> <div class="container-fluid">
<?php <?php
$extraFooterScripts = array(); $extraFooterScripts = array();
// handle page actions // handle page actions
switch ($page) { switch ($page) {
case "wlan0_info": case "wlan0_info":
DisplayDashboard($extraFooterScripts); DisplayDashboard($extraFooterScripts);
break; break;
case "dhcpd_conf": case "dhcpd_conf":
DisplayDHCPConfig(); DisplayDHCPConfig();
break; break;
case "wpa_conf": case "wpa_conf":
DisplayWPAConfig(); DisplayWPAConfig();
break; break;
case "network_conf": case "network_conf":
DisplayNetworkingConfig(); DisplayNetworkingConfig();
break; break;
case "hostapd_conf": case "hostapd_conf":
DisplayHostAPDConfig(); DisplayHostAPDConfig();
break; break;
case "openvpn_conf": case "openvpn_conf":
DisplayOpenVPNConfig(); DisplayOpenVPNConfig();
break; break;
case "torproxy_conf": case "torproxy_conf":
DisplayTorProxyConfig(); DisplayTorProxyConfig();
break; break;
case "auth_conf": case "auth_conf":
DisplayAuthConfig($config['admin_user'], $config['admin_pass']); DisplayAuthConfig($config['admin_user'], $config['admin_pass']);
break; break;
case "save_hostapd_conf": case "save_hostapd_conf":
SaveTORAndVPNConfig(); SaveTORAndVPNConfig();
break; break;
case "theme_conf": case "theme_conf":
DisplayThemeConfig(); DisplayThemeConfig();
break; break;
case "data_use": case "data_use":
DisplayDataUsage($extraFooterScripts); DisplayDataUsage($extraFooterScripts);
break; break;
case "system_info": case "system_info":
DisplaySystem(); DisplaySystem();
break; break;
case "about": case "about":
DisplayAbout(); DisplayAbout();
break; break;
default: default:
DisplayDashboard($extraFooterScripts); DisplayDashboard($extraFooterScripts);
} }
?> ?>
</div><!-- /.container-fluid --> </div><!-- /.container-fluid -->
</div><!-- End of Main Content --> </div><!-- End of Main Content -->
@ -313,7 +313,7 @@ if ($_COOKIE['sidebarToggled'] == 'true' ) {
foreach ($extraFooterScripts as $script) { foreach ($extraFooterScripts as $script) {
echo ' <script type="text/javascript" src="' , $script['src'] , '"'; echo ' <script type="text/javascript" src="' , $script['src'] , '"';
if ($script['defer']) { if ($script['defer']) {
echo ' defer="defer"'; echo ' defer="defer"';
} }
echo '></script>' , PHP_EOL; echo '></script>' , PHP_EOL;
} }