var hanlders_arry = [];
function show_s_eventsms(){
var str1 ="<input type='text' id='s_event_sms'>"
var obj1 = document.getElementById("s_eventsms");
obj1.innerHTML = str1;
}
show_s_eventsms()
function show_s_eventsnmptrap(){
var str1 ="<input type='text' id='s_event_snmptrap'>"
var obj1 = document.getElementById("s_eventsnmptrap");
obj1.innerHTML = str1;
}
show_s_eventsnmptrap()
function show_s_eventdi(){
var xml_di_pro = "di_profile.xml";
var t=new Date()
var xmlurl=xml_di_pro+"?ZT="+t.getTime();
$.ajax({
url:xmlurl,
type:"GET",
dataType:"xml",
error: function(){
},
success: function(xml){
var xmlDoc=xml;
var obj1 = document.getElementById("s_eventdi");
var span_str = "<select id='s_event_di' xonchange=''>";
diprofile_name_arr = [];      //DI Profile Name
diprofile_enable_arr = [];    //Enable
for(var x=0;x<10;x++)
{
diprofile_rule_index = xmlDoc.getElementsByTagName("diprofile_rule_index")[x].childNodes[0];
if(diprofile_rule_index != null)
{
index = parseInt(diprofile_rule_index.nodeValue);
xml_index = (index-1);
diprofile_name = xml_getvalue(xmlDoc,"diprofile_name",xml_index);
diprofile_enable = xml_getvalue(xmlDoc,"diprofile_enable",xml_index);
var enable_check = (diprofile_enable == 1);
if(enable_check){ span_str += "<option value="+xml_index+">"+diprofile_name+"</option>" }
}
}
span_str += "</select>"
if(span_str.indexOf("<option") != -1){ obj1.innerHTML = span_str; }
var obj_undo1 = document.getElementById("s_evtm");
Foolproofing(obj_undo1,"e");
}
});
}
show_s_eventdi()
function show_s_responsedo(){
var xml_do_pro = "do_profile.xml";
var t=new Date()
var xmlurl=xml_do_pro+"?ZT="+t.getTime();
$.ajax({
url:xmlurl,
type:"GET",
dataType:"xml",
error:function(){
},
success:function(xml){
var xmlDoc=xml;
var obj1 = document.getElementById("s_responsedo");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","DO Profile")+"</td><td>";
span_str += "<select id='s_response_do' xonchange=''>";
doprofile_name_arr = [];      //DO Profile Name
doprofile_enable_arr = [];    //Enable
for(var x=0;x<10;x++)
{
doprofile_rule_index = xmlDoc.getElementsByTagName("doprofile_rule_index")[x].childNodes[0];
if(doprofile_rule_index != null)
{
index = parseInt(doprofile_rule_index.nodeValue);
xml_index = (index-1);
doprofile_name = xml_getvalue(xmlDoc,"doprofile_name",xml_index);
doprofile_enable = xml_getvalue(xmlDoc,"doprofile_enable",xml_index);
var enable_check = (doprofile_enable == 1);
if(enable_check){ span_str += "<option value="+xml_index+">"+doprofile_name+"</option>" }
}
}
span_str += "</select>"
span_str +="</td></tr>";
span_str += "</table>";
if(span_str.indexOf("<option") != -1){ obj1.innerHTML = span_str; }
var obj_undo2 = document.getElementById("s_response");
Foolproofing(obj_undo2,"r");
}
});
}
function show_s_hanlderdo(){
var xml_do_pro = "do_profile.xml";
var t=new Date()
var xmlurl=xml_do_pro+"?ZT="+t.getTime();
$.ajax({
url:xmlurl,
type:"GET",
dataType:"xml",
error:function(){
},
success:function(xml){
var xmlDoc=xml;
var obj1 = document.getElementById("s_hanlderdo");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","DO Profile")+"</td><td>";
span_str += "<select id='s_hanlder_do' xonchange=''>";
doprofile_name_arr = [];      //DO Profile Name
doprofile_enable_arr = [];    //Enable
for(var x=0;x<10;x++)
{
doprofile_rule_index = xmlDoc.getElementsByTagName("doprofile_rule_index")[x].childNodes[0];
if(doprofile_rule_index != null)
{
index = parseInt(doprofile_rule_index.nodeValue);
xml_index = (index-1);
doprofile_name = xml_getvalue(xmlDoc,"doprofile_name",xml_index);
doprofile_enable = xml_getvalue(xmlDoc,"doprofile_enable",xml_index);
var enable_check = (doprofile_enable == 1);
if(enable_check){ span_str += "<option value="+xml_index+">"+doprofile_name+"</option>" }
}
}
span_str += "</select>"
span_str +="</td></tr>";
span_str += "</table>";
if(span_str.indexOf("<option") != -1){ obj1.innerHTML = span_str; }
}
});
}
show_s_hanlderdo()
function copytohid(obj){
var fm = obj.form
var str1 = obj.name;  //id=r_hanlder_wanA"+s
var obj1 = document.getElementById("s"+str1); //id=sr_hanlder_wanA...
var obj2 = document.getElementById("h"+str1); //id=hr_hanlder_wanA...
var rleg = eval("fm."+str1+".length")
var ary1 = (obj1.innerHTML).split('~')  //[0]=LTE-1 Reconnect ~ [1]=LTE-1 Disconnect
for(var s=0;s<rleg;s++){
var sw1 = eval("fm."+str1+"["+s+"].checked")
if(sw1){
obj2.value = ary1[s];
break
}
}
}
var lte_ary = new Array(
"0_1",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
"0_0",
""
)
var Cellular_ary0 = new Array(
" LTE", // 1:No LTE
" 3G", // 1:No 3G
" Prefer 2G"  // 1:No 2G
)
var Cellular_ary1 = new Array(
" LTE", //1:No LTE
" 3G", //1:No 3G
" Prefer 2G" //1:No 2G
)
function show_s_hanlderwan(){
var str1 ="";
var obj1 = document.getElementById("s_hanlderwan");  //hs_hanlderwan
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
for(var a=0;a<lte_ary.length;a++){ if(lte_ary[a]=="1_1"){ str1+="Cellular-"+(a+1)+"|" } }
var ary1 = str1.split('|')
for(var s=0;s<ary1.length;s++){
if(ary1[s] !=""){
var show_str0 = ary1[s]+" Connect"
var show_str1 = ary1[s]+" Disconnect"
span_str +="<tr><td class='evt_width1 evt_padding'>"+ary1[s]+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_wanA"+s+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Connect")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_wanA"+s+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Disconnect")+"&nbsp;&nbsp;"+
"<span id=sr_hanlder_wanA"+s+" style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderwan id=hr_hanlder_wanA"+s+">";
span_str +="</td></tr>";
strx = "r_hanlder_wanA"+s+"|"+show_str0+"~"+show_str1;
hanlders_arry.push(strx);
}
}
for(var s=0;s<ary1.length;s++){
if(ary1[s] !=""){
var Cellular_ary = (s == 0)?Cellular_ary0:Cellular_ary1;
var show_str0 = ary1[s]+" Auto"
var show_str1 = ary1[s]+Cellular_ary[0]//" LTE"
var show_str2 = ary1[s]+Cellular_ary[1]//" 3G"
var show_str3 = ary1[s]+Cellular_ary[2]//" Prefer 2G"
var show_str4 = show_str0;
span_str +="<tr><td class='evt_width1 evt_padding'>"+ary1[s]+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_wanB"+s+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Auto")+"&nbsp;&nbsp;";
if(Cellular_ary[0].lastIndexOf('x') == -1){
span_str +="<input type=radio value=1 name=r_hanlder_wanB"+s+" onclick='copytohid(this)'>LTE"+"&nbsp;&nbsp;";
show_str4 += "~"+show_str1;
}
if(Cellular_ary[1].lastIndexOf('x') == -1){
span_str +="/<input type=radio value=2 name=r_hanlder_wanB"+s+" onclick='copytohid(this)'>3G"+"&nbsp;&nbsp;";
show_str4 += "~"+show_str2;
}
if(Cellular_ary[2].lastIndexOf('x') == -1){
span_str +="/<input type=radio value=3 name=r_hanlder_wanB"+s+" onclick='copytohid(this)'>"+GetElmCont("mevt_0","Prefer 2G")+"&nbsp;&nbsp;";
show_str4 += "~"+show_str3
}
span_str +="<span id=sr_hanlder_wanB"+s+" style='display:none'>"+show_str4+"</span>";
span_str +="<input type=hidden class=hHh name=hs_hanlderwan id=hr_hanlder_wanB"+s+">";
span_str +="</td></tr>";
strx = "r_hanlder_wanB"+s+"|"+show_str4
hanlders_arry.push(strx);
}
}
for(var s=0;s<ary1.length;s++){
if((ary1[s] !="")&&( '1' == '1' )){
var show_str0 = ary1[s]+" SIM Switch to SIM-A"
var show_str1 = ary1[s]+" SIM Switch to SIM-B"
span_str +="<tr><td class='evt_width1 evt_padding'>"+ary1[s]+" "+GetElmCont("mevt_0","SIM Switch to")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_wanC"+s+" onclick='copytohid(this)'>SIM-A"+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_wanC"+s+" onclick='copytohid(this)'>SIM-B"+"&nbsp;&nbsp;"+
"<span id=sr_hanlder_wanC"+s+" style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderwan id=hr_hanlder_wanC"+s+">"
span_str +="</td></tr>";
strx = "r_hanlder_wanC"+s+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
}
}
span_str +="</table>";
obj1.innerHTML = span_str
}
show_s_hanlderwan()
function show_s_hanlderlanvlan(){
var obj1 = document.getElementById("s_hanlderlanvlan");
var span_str="<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
for(s = port_start ; s < port_count ; s++){
if(wanfix==0 && wanable==0 && have_adsl==1 && s==1){ s=s+1; }
var _s = get_portnumber(s)
var show_str0 = "Port-"+_s+" Link On"
var show_str1 = "Port-"+_s+" Link Off"
span_str +="<tr><td class='evt_width1 evt_padding'>Port-"+_s+" "+GetElmCont("mevt_0","Link")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_lanvlanA"+_s+" onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_lanvlanA"+_s+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanlder_lanvlanA"+_s+" style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderlanvlan id=hr_hanlder_lanvlanA"+_s+">";
span_str +="</td></tr>";
strx = "r_hanlder_lanvlanA"+_s+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
}
span_str +="</table>";
obj1.innerHTML = span_str
}
show_s_hanlderlanvlan()
function show_s_hanlderwifi2(){
var str1 ="";
var obj1 = document.getElementById("s_hanlderwifi");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var allwifi = false ;
var sw5g = false , sw2_4g = false ;
if(((4 != 0)&&(0 == 0))||((24 != 0)&&(1 == 0))){
sw2_4g = true ;   // Display WiFi 2.4G item
}
if(((4 != 0)&&(0 == 1))||((24 != 0)&&(1 == 1))){
sw5g = true ;   // Display WiFi 5G item
}
if(allwifi || sw2_4g){
var show_str0 = "2.4G WiFi On"
var show_str1 = "2.4G WiFi Off"
span_str +="<tr><td class='evt_width1 evt_padding'>2.4G</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_wifiA onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_wifiA onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanlder_wifiA style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderwifi id=hr_hanlder_wifiA>"
span_str +="</td></tr>";
strx = "r_hanlder_wifiA"+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
}
if(allwifi || sw5g){
var show_str2 = "5G WiFi On"
var show_str3 = "5G WiFi Off"
span_str +="<tr><td class='evt_width1 evt_padding'>5G</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_wifiB onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_wifiB onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanlder_wifiB style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderwifi id=hr_hanlder_wifiB>"
span_str +="</td></tr>";
strx = "r_hanlder_wifiB"+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
}
span_str +="</table>";
obj1.innerHTML = span_str
}
show_s_hanlderwifi2()
var isNAT = true ;
if((typeof(swm_nat_g2)!="undefined")&&(swm_nat_g2==true)){ isNAT = true /* swm_nat_g2 for GC0*/ }
function show_s_hanldernat(){
var obj1 = document.getElementById("s_hanldernat");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var show_str0 = "Virtual Server Rule-1 On"
var show_str1 = "Virtual Server Rule-1 Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","Virtual Server Rule")+"-1</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_natA onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_natA onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_natA style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanldernat id=hr_hanlder_natA>"
span_str +="</td></tr>";
strx = "r_hanlder_natA"+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
var show_str2 = "Virtual Server Rule-2 On"
var show_str3 = "Virtual Server Rule-2 Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","Virtual Server Rule")+"-2</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_natB onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_natB onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_natB style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanldernat id=hr_hanlder_natB>"
span_str +="</td></tr>";
strx = "r_hanlder_natB"+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
var show_str4 = "Virtual Server Rule-3 On"
var show_str5 = "Virtual Server Rule-3 Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","Virtual Server Rule")+"-3</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_natC onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_natC onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_natC style='display:none'>"+show_str4+"~"+show_str5+"</span>"+
"<input type=hidden class=hHh name=hs_hanldernat id=hr_hanlder_natC>"
span_str +="</td></tr>";
strx = "r_hanlder_natC"+"|"+show_str4+"~"+show_str5
hanlders_arry.push(strx);
var show_str6 = "DMZ On"
var show_str7 = "DMZ Off"
span_str +="<tr><td class='evt_width1 evt_padding'>DMZ</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_natD onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_natD onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_natD style='display:none'>"+show_str6+"~"+show_str7+"</span>"+
"<input type=hidden class=hHh name=hs_hanldernat id=hr_hanlder_natD>"
span_str +="</td></tr>";
strx = "r_hanlder_natD"+"|"+show_str6+"~"+show_str7
hanlders_arry.push(strx);
span_str += "</table>";
obj1.innerHTML = span_str
}
if(isNAT){ show_s_hanldernat() }
var isfirewall = true ;/* GC0 always show */
function show_s_hanlderfirewall(){
var obj1 = document.getElementById("s_hanlderfirewall");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var a3z_GC0 = 5 ; // from L123= a3z(GC0) - Remote Administrator Host Definition =5
for(var q=1;q<=a3z_GC0;q++){
var show_str0 = "Remote Administrator Host ID-"+q+" On";
var show_str1 = "Remote Administrator Host ID-"+q+" Off";
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","Remote Administrator Host ID")+"-"+q+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlderfirewallA"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlderfirewallA"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlderfirewallA"+q+" style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderfirewall id=hr_hanlderfirewallA"+q+">"
span_str +="</td></tr>";
strx = "r_hanlderfirewallA"+q+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
}
var show_str2 = "WAN Discard Ping On"
var show_str3 = "WAN Discard Ping Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","WAN Discard Ping")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlderfirewallB onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlderfirewallB onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlderfirewallB style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderfirewall id=hr_hanlderfirewallB>"
span_str +="</td></tr>";
strx = "r_hanlderfirewallB"+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
span_str += "</table>";
obj1.innerHTML = span_str
}
if(isfirewall){ show_s_hanlderfirewall() }
var isvpn = false ;
if((typeof(swm_s_vpn_g2)!="undefined")&&(swm_s_vpn_g2==true)){ isvpn = true }
function show_s_hanldervpn(){
var obj1 = document.getElementById("s_hanldervpn");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var e35_GC0 = 8 ; // from L123= e35(GC0) - IPSec Tunnel ID-n =8
var show_strE0 = "IPSec On"
var show_strE1 = "IPSec Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("wizvpn10_0","IPSec")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldervpnE"+" onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldervpnE"+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanldervpnE"+" style='display:none'>"+show_strE0+"~"+show_strE1+"</span>"+
"<input type=hidden class=hHh name=hs_hanldervpn id=hr_hanldervpnE>";
span_str +="</td></tr>";
strx = "r_hanldervpnE"+"|"+show_strE0+"~"+show_strE1
hanlders_arry.push(strx);
for(var q=1;q<=e35_GC0;q++){
var show_str0 = "IPSec Tunnel ID-"+q+" On"
var show_str1 = "IPSec Tunnel ID-"+q+" Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","IPSec Tunnel ID")+"-"+q+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldervpnA"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldervpnA"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanldervpnA"+q+" style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanldervpn id=hr_hanldervpnA"+q+">"
span_str +="</td></tr>";
strx = "r_hanldervpnA"+q+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
}
var show_str2 = "PPTP Client On"
var show_str3 = "PPTP Client Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("wizvpn20_0","PPTP Client")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldervpnB onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldervpnB onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanldervpnB style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanldervpn id=hr_hanldervpnB>"
span_str +="</td></tr>";
strx = "r_hanldervpnB"+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
var show_str4 = "L2TP Client On"
var show_str5 = "L2TP Client Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("wizvpn20_0","L2TP Client")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldervpnC onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldervpnC onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanldervpnC style='display:none'>"+show_str4+"~"+show_str5+"</span>"+
"<input type=hidden class=hHh name=hs_hanldervpn id=hr_hanldervpnC>"
span_str +="</td></tr>";
strx = "r_hanldervpnC"+"|"+show_str4+"~"+show_str5
hanlders_arry.push(strx);
var show_str6 = "OpenVPN Client On"
var show_str7 = "OpenVPN Client Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","OpenVPN Client")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldervpnD onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldervpnD onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanldervpnD style='display:none'>"+show_str6+"~"+show_str7+"</span>"+
"<input type=hidden class=hHh name=hs_hanldervpn id=hr_hanldervpnD>"
span_str +="</td></tr>";
strx = "r_hanldervpnD"+"|"+show_str6+"~"+show_str7
hanlders_arry.push(strx);
span_str += "</table>";
obj1.innerHTML = span_str
}
if(isvpn){ show_s_hanldervpn() }
else{
var obj1 = document.getElementById("s_sw_hanlder_VPN");
obj1.innerHTML = "";
}
var isgre = false ;
if(((typeof(swm_s_vpn_g2)!="undefined")&&(swm_s_vpn_g2==true))&&
((typeof(swm_s_gre_g2)!="undefined")&&(swm_s_gre_g2==true))){ isgre = true }
function show_s_hanldergre(){
var obj1 = document.getElementById("s_hanldergre");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var e35_GC0 = 8 ; // from L123= e35(GC0) - GRE Tunnel ID-n =8
var show_str0 = "GRE On"
var show_str1 = "GRE Off "
span_str +="<tr><td class='evt_width1 evt_padding'>GRE</td><td>";
span_str +="<input type=radio value=0 name=r_hanldergreA onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldergreA onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanldergreA style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanldergre id=hr_hanldergreA>"
span_str +="</td></tr>";
strx = "r_hanldergreA"+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
for(var q=1;q<=e35_GC0;q++){
var show_str2 = "GRE Tunnel ID-"+q+" On";
var show_str3 = "GRE Tunnel ID-"+q+" Off";
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("gre_0","GRE Tunnel")+"ID-"+q+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanldergreB"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanldergreB"+q+" onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;&nbsp;"+
"<span id=sr_hanldergreB"+q+" style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanldergre id=hr_hanldergreB"+q+">"
span_str +="</td></tr>";
strx = "r_hanldergreB"+q+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
}
span_str += "</table>";
obj1.innerHTML = span_str
}
if(isgre){ show_s_hanldergre() }
else{
var obj1 = document.getElementById("s_sw_hanlder_gre");
obj1.innerHTML = "";
}
var ismanagement = true ;
if((typeof(swm_management)!="undefined")&&(swm_management==true)){ ismanagement = true }
function show_s_hanldersystemmanagement(){
var obj1 = document.getElementById("s_hanldersystemmanagement");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var show_str0 = "WAN SSH Service On"
var show_str1 = "WAN SSH Service Off"
span_str +="<tr><td class='evt_width1 evt_padding'>"+GetElmCont("mevt_0","WAN SSH Service")+"</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_systemmanagementA onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_systemmanagementA onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_systemmanagementA style='display:none'>"+show_str0+"~"+show_str1+"</span>"+
"<input type=hidden class=hHh name=hs_hanldersystemmanagement id=hr_hanlder_systemmanagementA>"
span_str +="</td></tr>";
strx = "r_hanlder_systemmanagementA"+"|"+show_str0+"~"+show_str1
hanlders_arry.push(strx);
var show_str2 = "TR-069 On"
var show_str3 = "TR-069 Off"
span_str +="<tr><td class='evt_width1 evt_padding'>TR-069</td><td>";
span_str +="<input type=radio value=0 name=r_hanlder_systemmanagementB onclick='copytohid(this)'>"+GetElmCont("wary_0","On")+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_systemmanagementB onclick='copytohid(this)'>"+GetElmCont("wary_0","Off")+"&nbsp;"+
"<span id=sr_hanlder_systemmanagementB style='display:none'>"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanldersystemmanagement id=hr_hanlder_systemmanagementB>"
span_str +="</td></tr>";
strx = "r_hanlder_systemmanagementB"+"|"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
span_str += "</table>";
obj1.innerHTML = span_str
}
if(ismanagement){ show_s_hanldersystemmanagement() }
var isadminis = true ;/* GC0 always show */
function show_s_hanlderadministration(){
var obj1 = document.getElementById("s_hanlderadministration");
var span_str = "<table width='95%' border='0' align='center' cellpadding='0' cellspacing='0' class='linetab1'>";
var show_str0 = "Backup config"
var show_str1 = "Restore specific config"
var show_str2 = "Reboot"
var show_str3 = "Save current configuration as default"
span_str +="<tr><td class='evt_padding'>";
span_str +="<input type=radio value=0 name=r_hanlder_administrationA onclick='copytohid(this)'>"+GetElmCont("mevt_0",show_str0)+"&nbsp;&nbsp;/"+
"<input type=radio value=1 name=r_hanlder_administrationA onclick='copytohid(this)'>"+GetElmCont("mevt_0",show_str1)+"&nbsp;&nbsp;/"+
"<input type=radio value=2 name=r_hanlder_administrationA onclick='copytohid(this)'>"+GetElmCont("rebo_0",show_str2)+"&nbsp;&nbsp;/"+
"<input type=radio value=3 name=r_hanlder_administrationA onclick='copytohid(this)'>"+GetElmCont("mevt_0",show_str3)+"&nbsp;"+
"<span id=sr_hanlder_administrationA style='display:none'>"+show_str0+"~"+show_str1+"~"+show_str2+"~"+show_str3+"</span>"+
"<input type=hidden class=hHh name=hs_hanlderadministration id=hr_hanlder_administrationA>"
span_str +="</td></tr>";
strx = "r_hanlder_administrationA"+"|"+show_str0+"~"+show_str1+"~"+show_str2+"~"+show_str3
hanlders_arry.push(strx);
span_str += "</table>";
obj1.innerHTML = span_str
}
if(isadminis){ show_s_hanlderadministration() }