1 /* -------------------------------------------------------------------------- */
3 (c) 2004-2005 U.S. Robotics Corporation.
5 /* -------------------------------------------------------------------------- */
10 User name: "admin" or "power" or "user"
11 Standard: "annex_c" or ... what?
12 Protocol: "Bridge" or ... what?
19 function createMenu(strUsername, strStd, strProtocol, bIPext, bFirewall, bNAT, strWireless, bQoS)
21 if (strUsername == "user")
22 return createMenuUser(strWireless);
24 return createMenuAdmin(strStd, strProtocol, bIPext, bFirewall, bNAT, strWireless, bQoS);
28 /* --------------------------------------------------------------------------
30 These represent the various menus. There is a main menu bar and some sub-menus.
32 The second and third strings in each item need to be translated.
33 The first string is a filename and does not need to be translated.
35 This is the only section that contains text to be translated.
37 The tag below must not be modified. It is used by
38 Translation to extract the text to be translated.
39 *** TRANSLATION START -->
42 // N.B.: All filenames must be in lowercase here.
44 function createMenuUser(strWireless)
46 var bar = new MenuBar(7);
48 var dropdown = bar.addDropdown("Status", 10);
49 dropdown.addItem("General", "", "info.html");
50 dropdown.addItem("DSL", "", "wancfg.cmd?action=view");
51 dropdown.addItem("System Log", "", "logintro.html");
52 dropdown.addItem("LAN Statistics", "", "statsifc.html");
53 dropdown.addItem("WAN Statistics", "", "statswan.cmd");
54 dropdown.addItem("ATM Statistics", "", "statsatm.cmd");
55 dropdown.addItem("ADSL Statistics", "", "statsadsl.html");
57 dropdown = bar.addDropdown("LAN", 10);
58 dropdown.addItem("Routing - Routing Table", "", "rtroutecfg.cmd?action=view");
59 dropdown.addItem("Routing - ARP Table", "", "arpview.cmd");
61 dropdown = bar.addDropdown("Device", 10);
62 dropdown.addItem("Back up Settings", "", "backupsettings.html");
63 dropdown.addItem("Diagnostics", "", "diag.html");
64 if (strWireless == "1")
65 dropdown.addItem("SNMP", "", "snmpconfig.html");
71 function createMenuAdmin(strStd, strProtocol, bIPext, bFirewall, bNAT, strWireless, bQoS)
73 var bar = new MenuBar(7);
78 var dropdown = bar.addDropdown("Status", 10);
79 dropdown.addItem("General", "", "info.html");
80 dropdown.addItem("DSL", "", "wancfg.cmd?action=view");
81 dropdown.addItem("System Log", "", "logview.cmd");
82 dropdown.addItem("LAN Statistics", "", "statsifc.html");
83 dropdown.addItem("WAN Statistics", "", "statswan.cmd");
84 dropdown.addItem("ATM Statistics", "", "statsatm.cmd");
85 dropdown.addItem("ADSL Statistics", "", "statsadsl.html");
91 dropdown = bar.addDropdown("Internet", 17);
92 dropdown.addItem("WAN Setup", "", "wancfg.cmd");
93 if (strStd == "annex_c")
94 dropdown.addItem("ADSL Settings", "", "adslcfgc.html");
96 dropdown.addItem("ADSL Settings", "", "adslcfg.html");
98 if ( ((strProtocol == "PPPoE") && !bIPext) ||
99 ((strProtocol == "PPPoA") && !bIPext) ||
100 (strProtocol == "MER") ||
101 (strProtocol == "IPoA"))
103 dropdown.addItem("Default Gateway", "", "rtdefaultcfg.html");
104 dropdown.addItem("DNS Server", "", "dnscfg.html");
107 if (strProtocol != "Bridge")
109 dropdown.addItem("Access Control - IP Addresses", "", "scacccntr.cmd?action=view");
110 dropdown.addItem("Access Control - Services", "", "scsrvcntr.cmd?action=view");
112 dropdown.addItem("Dynamic DNS", "", "ddnsmngr.cmd");
118 if ( ((strProtocol == "PPPoE") && !bIPext) ||
119 ((strProtocol == "PPPoA") && !bIPext) ||
120 (strProtocol == "MER") ||
121 (strProtocol == "IPoA") ||
122 (strProtocol == "Bridge"))
124 dropdown = bar.addDropdown("LAN", 13);
125 if ( ((strProtocol == "PPPoE") && !bIPext) ||
126 ((strProtocol == "PPPoA") && !bIPext) ||
127 (strProtocol == "MER") ||
128 (strProtocol == "IPoA"))
130 dropdown.addItem("DHCP Server", "", "lancfg2.html");
131 dropdown.addItem("Mapped Interfaces", "", "portmap.cmd");
132 dropdown.addItem("Routing - Routing Table", "", "rtroutecfg.cmd?action=view");
133 dropdown.addItem("Routing - Static Routes", "", "rtroutecfg.cmd?action=viewcfg");
134 dropdown.addItem("Routing - RIP", "", "ripcfg.cmd?action=view");
135 dropdown.addItem("Routing - ARP Table", "", "arpview.cmd");
136 dropdown.addItem("DHCP Clients", "", "dhcpinfo.html");
138 dropdown.addItem("Quality of Service", "", "qoscls.cmd?action=view");
140 else if (strProtocol == "Bridge")
142 dropdown.addItem("DHCP Server", "", "lancfg2.html");
143 dropdown.addItem("Mapped Interfaces", "", "portmap.cmd");
146 dropdown.addItem("Quality of Service", "", "qoscls.cmd?action=view");
154 if (strWireless == "1")
156 dropdown = bar.addDropdown("Wireless", 11);
157 dropdown.addItem("Setup", "", "wlcfg.html");
158 dropdown.addItem("Client List", "", "wlstationlist.cmd?");
159 dropdown.addItem("AP Mode", "", "wlwds.cmd?action=view");
160 dropdown.addItem("Advanced Settings", "", "wlcfgadv.html");
161 dropdown.addItem("Quality of Service", "", "wlqos.cmd");
168 dropdown = bar.addDropdown("Security", 17);
169 if (strWireless == "1")
171 dropdown.addItem("Wireless", "", "wlsecurity.html");
172 dropdown.addItem("MAC Filter", "", "wlmacflt.cmd?action=view");
174 //WHY? if (strProtocol != "Bridge")
175 dropdown.addItem("Device Login", "", "password.html");
176 if ((strProtocol != "Not Applicable") && !bIPext)
178 if (strProtocol == "Bridge")
180 dropdown.addItem("Internet Access Control", "", "todmngr.tod?action=view");
181 dropdown.addItem("LAN MAC Filter", "", "scmacflt.cmd?action=view");
185 If it's not a bridge and the firewall is on, display filter commands
187 if ((strProtocol != "Bridge") && bFirewall)
189 dropdown.addItem("Internet Access Control", "", "todmngr.tod?action=view");
190 dropdown.addItem("IP Filtering - Outbound Filters", "", "scoutflt.cmd?action=view");
191 dropdown.addItem("IP Filtering - Inbound Filters", "", "scinflt.cmd?action=view");
195 If NAT is enabled, display virtual server commands
199 dropdown.addItem("Virtual Servers", "", "scvrtsrv.cmd?action=view");
200 dropdown.addItem("Port Triggering", "", "scprttrg.cmd?action=view");
201 dropdown.addItem("DMZ Host", "", "scdmz.html");
209 dropdown = bar.addDropdown("Device", 10);
210 dropdown.addItem("Time", "", "sntpcfg.html");
211 dropdown.addItem("Print Server", "", "ippcfg.html");
212 dropdown.addItem("Back Up Settings", "", "backupsettings.html");
213 dropdown.addItem("Restore Settings", "", "updatesettings.html");
214 dropdown.addItem("Restart", "", "resetrouter.html");
215 dropdown.addItem("Upgrade", "", "upload.html");
216 dropdown.addItem("Restore Defaults", "", "defaultsettings.html");
217 dropdown.addItem("Diagnostics", "", "diag.html");
218 if (strWireless == "1")
219 dropdown.addItem("SNMP", "", "snmpconfig.html");
225 <-- TRANSLATION END ***
226 Nothing after this needs to be translated.
227 The above tag must not be modified. It is used by
228 Translation to extract the text to be translated.