#!/usr/bin/webif-page >|required' && { FORM_dns="$LISTVAL" save_setting network wifi_dns "$FORM_dns" } FORM_dnsadd=${FORM_dnsadd:-192.168.1.1} if empty "$FORM_submit"; then FORM_wifi_enable="${wifi_enable:-$(nvram get wifi_proto)}" case "$FORM_wifi_enable" in static) ;; *) FORM_wifi_enable=none ;; esac lan_interfaces_save=$($lan_interfaces_current |sed s/$wifi_interface//) case "$FORM_wifi_enable" in static) FORM_wifi_ipaddr=${wifi_ipaddr:-$(nvram get wifi_ipaddr)} FORM_wifi_netmask=${wifi_netmask:-$(nvram get wifi_netmask)} FORM_wifi_gateway=${wifi_gateway:-$(nvram get wifi_gateway)} ;; esac else case "$FORM_wifi_enable" in static) SAVED=1 validate <>|required|$FORM_wifi_ipaddr netmask|FORM_wifi_netmask|@TR<>|required|$FORM_wifi_netmask ip|FORM_wifi_gateway|@TR<>||$FORM_wifi_gateway EOF equal "$?" 0 && { save_setting wifi-enable lan_ifnames "$lan_interfaces_save" save_setting wifi-enable wifi_ifnames $wifi_interface save_setting wifi-enable wifi_ifname br$br_num save_setting wifi-enable wifi_stp "1" save_setting wifi-enable wifi_proto "static" save_setting wifi-enable wifi_ipaddr $FORM_wifi_ipaddr save_setting wifi-enable wifi_netmask $FORM_wifi_netmask save_setting wifi-enable wifi_gateway $FORM_wifi_gateway } ;; *) # Do all the nvram varaibles need to be unset? save_setting wifi-disable lan_ifnames "$lan_interfaces_save $wifi_interface" save_setting wifi-disable wifi_ifnames "" save_setting wifi-disable wifi_ifname "" save_setting wifi-disable wifi_stp "" save_setting wifi-disable wifi_proto "" save_setting wifi-disable wifi_ipaddr "" save_setting wifi-disable wifi_netmask "" save_setting wifi-disable wifi_gateway "" save_setting wifi-disable wifi_dns "" ;; esac fi header "Network" "WIFI-LAN" "@TR<>" ' onLoad="modechange()" ' "$SCRIPT_NAME" cat < EOF display_form <> field|@TR<>|||When you split the Wireless LAN from the bridge the wired and and wireless traffic will no longer see each other. select|wifi_enable|$FORM_wifi_enable option|none|@TR<> option|static|@TR<> helpitem|Enable/Disable helptext|Helptext Enable/Disable#When this is enabled it will remove your wireless interface from the bridge with your switch and put it in its own bridge on a seperate subnet. helpitem|WLAN helptext|termtext WLAN#WLAN stands for "Wireless LAN". end_form start_form|@TR<>|wifi_config|hidden field|@TR<> text|wifi_ipaddr|$FORM_wifi_ipaddr helpitem|IP Address helptext|Helptext IP Address#This is the address you want this device to have on your Wireless LAN. field|@TR<> text|wifi_netmask|$FORM_wifi_netmask helpitem|Netmask helptext|Helptext Netmask#This bitmask indicates what addresses are included in your Wireless LAN. For those who don't know what a bitmask is, just think of "255" as 'match this part' and "0" as 'any number here'. field|@TR<> text|wifi_gateway|$FORM_wifi_gateway end_form start_form|@TR<>|wifi_dns|hidden listedit|dns|$SCRIPT_NAME?|$FORM_dns|$FORM_dnsadd helpitem|Note helptext|Helptext DNS save#You need save your settings on this page before adding/removing DNS servers end_form EOF footer ?>