< div id = "main" >
< div class = "header" >
< h1 > Wifi Configuration< / h1 >
< / div >
< div class = "content" >
< div class = "pure-g" >
< div class = "pure-u-1 pure-u-md-1-2" > < div class = "card" >
< h1 > Wifi State< / h1 >
< div id = "wifi-spinner" class = "spinner spinner-small" > < / div >
< table id = "wifi-table" class = "pure-table pure-table-horizontal" hidden > < tbody >
< tr > < td > WiFi mode< / td > < td id = "wifi-mode" > < / td > < / tr >
< tr > < td > Wifi channel< / td > < td id = "wifi-chan" > < / td > < / tr >
< tr > < td > Configured network< / td > < td id = "wifi-ssid" > < / td > < / tr >
< tr > < td > Wifi status< / td > < td id = "wifi-status" > < / td > < / tr >
< tr > < td > Wifi address< / td > < td id = "wifi-ip" > < / td > < / tr >
< tr > < td > Wifi rssi< / td > < td id = "wifi-rssi" > < / td > < / tr >
< tr > < td > Wifi phy< / td > < td id = "wifi-phy" > < / td > < / tr >
< tr > < td > Wifi MAC< / td > < td id = "wifi-mac" > < / td > < / tr >
< tr > < td colspan = "2" id = "wifi-warn" > < / td > < / tr >
< / tbody > < / table >
< / div > < / div >
< div class = "pure-u-1 pure-u-md-1-2" > < div class = "card" >
< h1 > Wifi Association< / h1 >
< p id = "reconnect" style = "color: #600" hidden > < / p >
< form action = "#" id = "wifiform" class = "pure-form pure-form-stacked" >
< legend > To connect to a WiFi network, please select one of the detected networks,
enter the password, and hit the connect button...< / legend >
< label > Network SSID< / label >
< div id = "aps" > Scanning... < div class = "spinner spinner-small" > < / div > < / div >
< label > WiFi password, if applicable:< / label >
< input id = "wifi-passwd" type = "password" name = "passwd" placeholder = "password" >
< button id = "connect-button" type = "submit" class = "pure-button button-primary" > Connect!< / button >
< / form >
< / div > < / div >
< / div >
< div class = "pure-g" >
< div class = "pure-u-1 pure-u-md-1-2" > < div class = "card" >
< h1 > Special Settings< / h1 >
< form action = "#" id = "specform" class = "pure-form" >
< legend > Special settings, use with care!< / legend >
< div class = "form-horizontal" >
< label for = "dhcp-ron" style = "margin-right:1em" >
< input type = "radio" name = "dhcp" value = "on" id = "dhcp-ron" / >
DHCP< / label >
< label for = "dhcp-roff" >
< input type = "radio" name = "dhcp" value = "off" id = "dhcp-roff" / >
Static IP< / label >
< / div >
< div id = "dhcp-on" class = "pure-form-stacked" >
< label > Hostname when requesting DHCP lease< / label >
< input id = "wifi-hostname" type = "text" name = "hostname" / >
< / div >
< div id = "dhcp-off" class = "pure-form-stacked" >
< label > Static IP address< / label >
< input id = "wifi-staticip" type = "text" name = "staticip" / >
< label > Netmask (for static IP)< / label >
< input id = "wifi-netmask" type = "text" name = "netmask" / >
< label > Gateway (for static IP)< / label >
< input id = "wifi-gateway" type = "text" name = "gateway" / >
< / div >
< button id = "special-button" type = "submit"
class="pure-button button-primary">Change!< / button >
< / form >
< / div > < / div >
< / div >
< / div >
< / div >
< / div >
< script type = "text/javascript" >
< / script >
< script src = "wifi.js" > < / script >
< script type = "text/javascript" >
onLoad(function() {
getWifiInfo();
bnd($("#wifiform"), "submit", changeWifiAp);
bnd($("#specform"), "submit", changeSpecial);
bnd($("#dhcp-ron"), "click", doDhcp);
bnd($("#dhcp-roff"), "click", doStatic);
scanTimeout = window.setTimeout(scanAPs, 500);
});
< / script >
< / body > < / html >