1/******* 2Original JS 3******/ 4 5var isVertical = false; 6var l_scr_total_width = screen.width; 7var add_subnavig_type = ''; 8 9 10var subng_variation_flag = "OLDDESIGN"; 11var navigation_align = "hp_right_align"; 12var horizontal_location = "t"; 13var vertical_location = "t"; 14 15var xUA=navigator.userAgent.toLowerCase(); 16 17 xIE4=xUA.indexOf('msie 4')!=-1; 18 xIE5=xUA.indexOf('msie 5')!=-1; 19 xIE6=xUA.indexOf('msie 6')!=-1; 20 21var cursorType= ""; 22 23 if(xIE4 || xIE5) 24 cursorType = 'CURSOR:HAND; ' ; 25 else 26 cursorType = 'cursor: hand; cursor: pointer; '; 27 28// General Data 29 var browser_type = navigator.appName; //browser type 30 var main_cat_arr = main_cat.split("::"); //main navis array 31 var main_cat_length = main_cat_arr.length; //length 32 var main_sub_cat_arr = sub_cat.split(","); //sub navis array 33 var main_sub_cat_length = main_sub_cat_arr.length; //sub navis length 34 var main_sub_cat_ext_arr = sub_cat_ext.split(","); // sub navis array 35 var main_sub_cat_ext_length = main_sub_cat_ext_arr.length; // sub navis length 36 var STR_IE = "Microsoft Internet Explorer"; //ie 37 var STR_NS = "Netscape"; //netscape 38 var STR_GECKO = "Gecko"; //gecko 39 var STR_YES = "yes"; //yew 40 var STR_NO = "no"; //no 41 42 var f_str_dyn_sub_list = new Array(); 43 44// NS Properties 45 var ns_sub_def_width ; //width 46 var ns_sub_def_height ; //height 47 var ns_sub_def_left; //left 48 var ns_sub_start_top; //top 49 var ns_sub_inc_top; //increment top 50 var ns_top_variance; // variance 51 //IE Properties 52 var ie_sub_def_width; //width 53 var ie_sub_def_height; //height 54 var ie_sub_def_left; //left 55 var ie_sub_start_top; //top 56 var ie_sub_inc_top; //increment top 57 var ie_down_key_status; //key status 58 var ie_current_hid_index; //index 59 60//sub layer position inIE 61 var ie_poistion_details = new Array(); //position list 62 63//BACKGROUND IMAGE 64 var img_over = ""; //image over 65 var img_out = ""; //image out; 66 67// Sub navigation enable 68 var bln_navigation_state = true; //state 69 70// dyn layers height height 71 var ns_layers_height; //height 72 73// common top & left 74 var dyn_top; //top 75 var dyn_left; //left 76 77//current page id & url status 78 var current_page_id = ""; //current page id 79 var current_url_status = ""; //current url 80 var current_url_name = ""; //current url name for external link 81 var current_url_tgt = ""; //current url 82 83//Identify cell No 84 var current_cell = ""; // cell details 85
86 document.write('<style type="text/css">'); 87 document.write('<!--'); 88 document.write('.titlesize {'); 89 document.write('font-family: Verdana, Arial, Helvetica, sans-serif;'); 90 document.write('font-size: 11px;'); 91 document.write('font-weight: normal;'); 92 document.write('text-decoration: none;'); 93 document.write('}'); 94 document.write('-->'); 95 document.write('</style>'); 96 97// style sheet properties for ns 98 document.write('<STYLE TYPE="text/javascript">'); 99 document.write('classes.borderinclass.all.borderWidths("1pt");'); 100 document.write('classes.borderinclass.all.borderStyle="inset";'); 101 document.write('classes.borderinclass.all.borderColor="#b2b2b2";'); 102 document.write('classes.borderoutclass.all.borderWidths("1pt");'); 103 document.write('classes.borderoutclass.all.borderStyle="outset";'); 104 document.write('classes.borderoutclass.all.borderColor="#b2b2b2";'); 105 document.write('</STYLE>'); 106 107//cell properties 108 var l_str_dtable_starts = "<table width='" + l_int_width + "' height='" + l_int_height + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='" + l_str_ver_align + "' align='" + title_align + "'><font color='" + default_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 1 109 var l_str_stable_starts = "<table width='" + l_int_width + "' height='" + l_int_height + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='" + l_str_ver_align + "' align='"+ title_align +"'><font color='" + scroll_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 2 110 var l_str_table_close = " </font></td></tr></table>"; //close the table 111 112// for ns layers 113 var l_str_dtable_starts_org = "<table width='" + l_int_width + "' height='" + l_int_height + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='middle' align='" + title_align + "'><font color='" + default_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 1 114 var l_str_stable_starts_org = "<table width='" + l_int_width + "' height='" + l_int_height + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='middle' align='"+ title_align +"'><font color='" + scroll_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 2 115 116 var _is_gecko_bowser = STR_NO; 117 var _browser_agent_type = navigator.userAgent; 118 119 if( _browser_agent_type != null && _browser_agent_type.indexOf(STR_GECKO) != -1 ) 120 { 121 _is_gecko_bowser = STR_YES; 122 //alert("in if 1"); 123 } 124 125 if( _browser_agent_type != null && _browser_agent_type.indexOf(STR_GECKO) != -1 && _browser_agent_type.indexOf(STR_NS) != -1 && browser_type.indexOf(STR_NS) != -1) 126 _is_gecko_bowser = STR_YES; 127 128 if(browser_type == STR_IE) 129 { //starts if 130 131 /*** starts sub navigation property ***/ 132 // temp layers 133 setIEAllSubNavis(); 134 document.onmousedown = getKeyDown; 135 /*** close sub navigation property ***/ 136 } // close if 137 else if(_is_gecko_bowser == STR_YES) // check gecko browser 138 { //starts if 139 // temp layers 140 //alert("isVertical "+isVertical); 141 //if(isVertical) 142 //{ 143 setGeckoAllSubNavisVertical(); 144 //} 145 //else 146 //{ 147 //setGeckoAllSubNavis(); 148 //} 149 document.onmousedown = getKeyDown; 150 } // close if 151 else if(browser_type == STR_NS) 152 { //starts else-if 153 154 /**** starts sub navigation property ****/ 155 document.write("<layer id='tlayer' width=0 height=0 top=0 onMouseover='clearNSSubNavi();' onMouseout='this.visibility=\"hide\";clearNSSubNavi();' left=0 visibility='hide' border-width=0><table width=" + ns_sub_def_width + " border=0 cellPadding=0 cellSpacing=0 height=" + ns_sub_def_height + " ><tr><td> </td></tr></table></layer>"); 156 document.write("<layer id='bglayer' width=0 height=0 top=0 onMouseover='' onMouseout='' left=0 visibility='hide' border-width=0><table width=" + ns_sub_def_width + " border=0 cellPadding=0 cellSpacing=0 height=" + ns_sub_def_height + " ><tr><td> </td></tr></table></layer>"); 157 158 for(var i=0;i<main_sub_cat_length;i++) 159 { // starts for loop 160 var lay = main_sub_cat_arr[i].split(":"); //array 161 var layer_active = 'act_' + lay[1]; //array active 162 // default layer 163 var l_str_data = ''; // strings collection 164 var l_str_arr_data = getNoStrings(lay[2]); // string list 165 var lay_ext = main_sub_cat_ext_arr[i].split("::"); //array 166 for(var k=0;k<l_str_arr_data.length;k++) 167 l_str_data += l_str_arr_data[k] +' '; 168 // default layer class=borderoutclass 169 document.write("<layer id='" + lay[1] + "' width=0 height=0 top=0 left=0 visibility='hide' onMouseOut='' onMouseOver='onSubNaviNSMouseOver(this,\"" + layer_active + "\");' >" + l_str_stable_starts_org + l_str_data + l_str_table_close + "</layer>"); 170 // active layers class=borderinclass 171 document.write("<layer id='" + layer_active + "' width=0 height=0 top=0 left=0 visibility='hide' onMouseOut='onSubNaviNSMouseOver(this,\"" + lay[1] + "\");' onMouseOver='onCurrentNSSubNavis(\"" + layer_active + "\",\"" + lay[3] + "\",\"" + lay_ext[1] + "\",\"" + lay_ext[2] + "\")' >" + l_str_dtable_starts_org + l_str_data + l_str_table_close + "</layer>"); 172 } //close the for loop 173 document.captureEvents(Event.MOUSEDOWN |Event.MOUSEUP); 174 document.onmouseup = getAction; 175 /**** close sub navigation property ****/ 176 } // close else if 177 178 /* clear all sublayer in general */ 179function getTop() 180{ 181 setClearSubLayer(main_sub_cat_length); 182} //close the function 183 184function getSubNavisOnly(main_navi) 185{ 186 var l_str_arr_subnavis = new Array(); //array 187 var l_str_arr_ipnos = new Array(); //array 188 var l_str_arr_result = new Array(); //array 189 var l_int_i = 0; //index 190 for(n=0;n<main_sub_cat_length;n++) 191 { //starts for -1 loop 192 var l_str_arr_temp = main_sub_cat_arr[n].split(':'); //array 193 if(l_str_arr_temp[0] == main_navi) 194 { 195 l_str_arr_subnavis[l_int_i] = l_str_arr_temp[1] + ':' + l_str_arr_temp[4]; 196 l_str_arr_ipnos[l_int_i] = l_str_arr_temp[4]; 197 l_int_i++; 198 } 199 } //close for-1 loop 200 var l_int_cnt = 0 //count 201 if(l_str_arr_ipnos.length>0) 202 { //starts if -non-empyt array 203 l_str_arr_ipnos.sort(); 204 l_str_arr_ipnos.sort(compareNumbers); 205 for(var j=0;j<l_str_arr_ipnos.length;j++) 206 { //starts for -outter; 207 for(var k=0;k < l_str_arr_subnavis.length; k++) 208 { //starts for -inner 209 var l_str_loc_data = l_str_arr_subnavis[k].split(':'); 210 if(l_str_loc_data[1] == l_str_arr_ipnos[j]) 211 l_str_arr_result[l_int_cnt++] = l_str_loc_data[0]; 212 }// inner loop-close 213 }//outter loop -close 214 } //close if 215 216 return l_str_arr_result; 217} // close the function 218 219function setClearSubLayer(slength) 220{ 221 if(browser_type == STR_IE) //if (ie) 222 clearIENavis(); 223 else if(_is_gecko_bowser == STR_YES) 224 clearGeckoNavis(); 225 else //starts else 226 { 227 if(browser_type == STR_NS) //if(ns) 228 setClearNSSubLayer(slength); 229 } //close the else 230} //close the function 231 232/* 233 This function returns list of individual strings about collection strings such as para or 234 line etc. 235*/ 236function getNoStrings(str) 237{ 238 var l_str_arr_strarray = new Array() //temp array 239 if(str != '') //non emty 240 l_str_arr_strarray = str.split(" "); 241 return l_str_arr_strarray; 242} //close the function 243 244function getScreenFixAbove1024(l) 245{ 246// alert(screen.width); 247 var l_width_pixel =eval(l); 248 var _broswertype =navigator.userAgent; // browser type 249 250 if(screen.width > 1024) 251 { 252 253 if(subng_variation_flag == "OLDDESIGN") // condition to old design 254 { 255 256 if(screen.width == 1280) // screen resultion to 1280 257 { 258 if( _broswertype.indexOf("Gecko") != -1 ) 259 l_width_pixel =l_width_pixel + 280; 260 else if( _broswertype.indexOf("MSIE") != -1) 261 l_width_pixel =l_width_pixel + 260; 262 } 263 else if( screen.width ==1152) //screen resultion to 1152 264 { 265 if( _broswertype.indexOf("Gecko") != -1 ) 266 l_width_pixel =l_width_pixel + 150; 267 268 else if( _broswertype.indexOf("MSIE") != -1) 269 l_width_pixel =l_width_pixel + 130; 270 271 } 272 else 273 { 274 l_width_pixel = eval(l+(Math.round(l_int_width/1.255))); 275 } 276 } 277 else if( subng_variation_flag == "NEWDESIGN" )// condtion to new design 278 l_width_pixel =l_width_pixel; 279 else // codition to inner page 280 { 281 if( screen.width == 1280) 282 l_width_pixel = l_width_pixel ; 283 else if(screen.width == 1152 ) 284 l_width_pixel = l_width_pixel ; 285 else 286 l_width_pixel = l_width_pixel ; 287 288 } 289 290 291 // l_width_pixel = eval(l+(Math.round(l_int_width/1.255))); 292 } 293 return l_width_pixel; 294} 295 296function displayMenu(evnt,width,height,nav_pos) 297{ 298 var x=0; 299 var y=0; 300 301 if(evnt==null) 302 evnt=window.event; 303 304 var targ; 305 var isIE=!(navigator.userAgent.indexOf("Gecko")!=-1); 306 if(isIE)
307 targ=evnt.srcElement; 308 else 309 targ=evnt.target; 310 //ObjectNode assign select_obj 311 312 var ObjectNode=targ; 313 //Iterate until ObjectNode is body 314 while(ObjectNode!=null) 315 { 316 //Set x as x+ObjectNode.offsetTop. 317 if(!isNaN(ObjectNode.offsetTop)) 318 y=y+ObjectNode.offsetTop; 319 320 if(!isNaN(ObjectNode.offsetLeft)) 321 x=x+ObjectNode.offsetLeft; 322 323 if(ObjectNode.offsetParent) 324 ObjectNode=ObjectNode.offsetParent; 325 else 326 ObjectNode=ObjectNode.parentNode; 327 } //end Iterate until ObjectNode is HTML 328 329 330 if(nav_pos == "left") 331 { 332 x+=targ.offsetWidth; 333 } 334 else if(nav_pos == "right") 335 { 336 if(x > 600 ) 337 { 338 x-=width; 339 340 } 341 else 342 { 343 x+=targ.offsetWidth; 344 } 345 } 346 return x; 347 348} 349 350function displayMenuy(evnt,width,height,nav_pos) 351{ 352 353 var x=0; 354 var y=0; 355 356 if(evnt==null) 357 evnt=window.event; 358 359 var targ; 360 var isIE=!(navigator.userAgent.indexOf("Gecko")!=-1); 361 if(isIE) 362 targ=evnt.srcElement; 363 else 364 targ=evnt.target; 365 //ObjectNode assign select_obj 366 367 var ObjectNode=targ; 368 //Iterate until ObjectNode is body 369 while(ObjectNode!=null) 370 { 371 //Set x as x+ObjectNode.offsetTop. 372 if(!isNaN(ObjectNode.offsetTop)) 373 y=y+ObjectNode.offsetTop; 374 375 if(!isNaN(ObjectNode.offsetLeft)) 376 x=x+ObjectNode.offsetLeft; 377 378 if(ObjectNode.offsetParent) 379 ObjectNode=ObjectNode.offsetParent; 380 else 381 ObjectNode=ObjectNode.parentNode; 382 } //end Iterate until ObjectNode is HTML 383 384 385 386 if(nav_pos == "top") 387 { 388 y+=targ.offsetHeight; 389 } 390 else if(nav_pos == "bottom") 391 { 392 y-=targ.offsetHeight; 393 if(targ.nodeName == "A" || targ.nodeName == "a") 394 { 395 //Text link navigations 396 y-=10; 397 var borderPixel = 2; 398 if(_is_gecko_bowser == STR_YES) 399 { 400 borderPixel = 4; 401 } 402 403 if(subNgCount > 1) 404 { 405 y-= (((subNgCount-1)*subNavigHeight)+((subNgCount+1)*borderPixel)); 406 y-= 1; 407 } 408 else 409 { 410 y-= ((subNgCount+1)*borderPixel); 411 } 412 } 413 } 414 return y; 415 416} 417 418var previousCat; 419var currentCat; 420var subNgCount = 1; 421var subNavigHeight; 422var subNavigWidth; 423function getSubLayers(nav_pos,evnt,curr_cat,index,start_top,start_left,img_default,img_over,height,width,latest_location) 424{ 425 subNavigWidth = width; 426 isVertical = false;
427 if(!latest_location) 428 { 429 //for hand symbol 430 if(nav_pos == "l" || nav_pos == "tl" || nav_pos == "bl") 431 { 432 latest_location = 'l'; 433 } 434 else 435 { 436 latest_location = 'r'; 437 } 438 } 439 if(nav_pos == "l") 440 { 441 vertical_location = nav_pos; 442 nav_pos = "left"; 443 } 444 else if(nav_pos == "r") 445 { 446 vertical_location = nav_pos; 447 nav_pos = "right"; 448 } 449 else if(nav_pos == "tl" || nav_pos == "tr") 450 { 451 horizontal_location = nav_pos; 452 nav_pos = "top"; 453 isVertical = true; 454 } 455 else if(nav_pos == "b" || nav_pos == "br" || nav_pos == "bl") 456 { 457 horizontal_location = nav_pos; 458 nav_pos = "bottom"; 459 isVertical = true; 460 } 461 462 subNavigHeight = height; 463 previousCat = currentCat; 464 if(previousCat) 465 { 466 hidePrevSubNavig(previousCat); 467 } 468 currentCat = curr_cat; 469 var l_str_arr_temp = getSubNavisOnly(curr_cat); //get acti navis 470 subNgCount = l_str_arr_temp.length; 471 472 start_left = displayMenu(evnt,width,height,nav_pos); 473 start_top = displayMenuy(evnt,width,height,nav_pos); 474 475 location_identifier =latest_location; 476 var l_int_ileft = start_left; 477 // if(latest_location == 'r' || navigation_align=="hp_right_align") 478 // l_int_ileft = getScreenFixAbove1024(start_left); 479 480 //f_str_dyn_sub_list =new Array(); 481 //alert("1f_str_dyn_sub_list "+f_str_dyn_sub_list); 482 common_height = height; 483 common_width = width; 484 common_top = start_top; 485 common_left = l_int_ileft; 486 common_inc = height; 487 488// NS Properties 489 ns_sub_def_width = width; 490 ns_sub_def_height = height; 491 ns_sub_inc_top = common_inc; 492// ns_sub_start_top = common_top+ns_top_variance; 493 ns_sub_start_top = common_top; 494// IE Properties 495 ie_sub_def_width = width; 496 ie_sub_def_height = height; 497 ie_sub_def_left = common_left; 498 ie_sub_start_top = common_top; 499 ie_sub_inc_top = common_inc; 500 501 if(_is_gecko_bowser == STR_YES) 502 { //starts if 503 dyn_top = start_top; 504 dyn_left = l_int_ileft; 505 if(isVertical) 506 { 507 setGeckoSubNavisListVertical(curr_cat,index,l_int_ileft,start_top,ie_sub_def_height,ie_sub_def_width); 508 } 509 else 510 { 511 setGeckoSubNavisList(curr_cat,index,l_int_ileft,start_top,ie_sub_def_height,ie_sub_def_width); 512 } 513 } 514 else if(browser_type == STR_IE) 515 { //starts if 516 dyn_top = start_top; 517 dyn_left = l_int_ileft; 518 setIESubNavisList(curr_cat,index,l_int_ileft,start_top,ie_sub_def_height,ie_sub_def_width); 519 } // close if 520 else 521 { //starts outter else 522 if(browser_type == STR_NS) //starts inner if 523 { 524 dyn_top = start_top; 525 dyn_left = l_int_ileft; 526 setNSSubLayers(curr_cat,index,start_top,l_int_ileft,img_default,img_over); 527 } //close the inner if 528 } //close the outter else 529} // close the function 530 531/****************************** Starts list of NS functions ****************************/ 532/* set dummy layers with respect to main/sun */ 533/* dynmic navigation from the main navigation*/ 534function setNSSubLayers(c_cat,index, start_top, start_left, img0, img1) 535{ 536 setClearSubLayer(main_sub_cat_length); 537 document.layers["tlayer"].visibility = "hide"; 538 var temp_sub_arr = getSubNavisOnly(c_cat); // array of sub navis 539 if(main_sub_cat_length > 0) 540 { //starts if-1 atlease on subnavis 541 if(temp_sub_arr.length > 0) 542 { //starts if-3 543 f_str_dyn_sub_list = temp_sub_arr; 544 ns_layers_height = 0; 545 ns_sub_start_top = start_top; 546 var position = index; //index 547 for(var i=0;i<temp_sub_arr.length;i++) 548 { //starts for loop 549 //var lay="sub_layer_"+i; 550 var layer_id = temp_sub_arr[i]; //array -temp 551 var act_layer = 'act_' + layer_id; // active layer 552 document.layers[layer_id].visibility = "show"; 553 document.layers[layer_id].top = ns_sub_start_top; 554 document.layers[act_layer].top = ns_sub_start_top; 555 document.layers[layer_id].left = start_left; 556 document.layers[act_layer].left = start_left; 557 img_over = img1; 558 img_out = img0; 559 document.layers[layer_id].background.src = img0; 560 document.layers[act_layer].background.src = img1; 561// document.layers[layer_id].bgcolor="#12acacac"; 562 document.layers[layer_id].resizeTo(eval(common_width),eval(common_height)); 563 document.layers[act_layer].resizeTo(eval(common_width ),eval(common_height));
564 ns_sub_start_top += ns_sub_inc_top+2; 565 ns_layers_height += ns_sub_def_height + 2; 566 position++; 567 } //close for loop 568 document.layers["tlayer"].visibility = "show"; 569 document.layers["tlayer"].resizeTo(eval(ns_sub_def_width + 40),eval(ns_layers_height + 40)); 570 document.layers["tlayer"].top = start_top - 5; 571// document.layers["tlayer"].left = start_left; 572 if(location_identifier == 'r') 573 document.layers["tlayer"].left = start_left-(eval(ns_sub_def_width/4)); 574 else if(location_identifier == 'l') 575 document.layers["tlayer"].left = start_left; //document.layers["tlayer"].left = start_left - 40; 576 else if(vertical_location == 'l') 577 document.layers["tlayer"].left = start_left; //document.layers["tlayer"].left = start_left - 40; 578 else if(vertical_location == 'r') 579 document.layers["tlayer"].left = start_left-(eval(ns_sub_def_width/4)); 580// document.layers["tlayer"].bgColor="#fafa00"; 581 document.layers["bglayer"].visibility = "show"; 582 document.layers["bglayer"].resizeTo(eval(ns_sub_def_width+4),eval(ns_layers_height+1)); 583 document.layers["bglayer"].top = start_top-1; 584 document.layers["bglayer"].left = start_left-1; 585 document.layers["bglayer"].bgColor='#b2b2b2'; 586 } //close if -3 587 } // over the if -1 588} // over the function 589 590function onSubNaviNSMouseOver(ilayer,slayer) 591{ 592 current_page_id = ''; //current page id 593 current_url_status = ''; //current url 594 current_url_name = ''; //current url for external link 595 current_url_tgt = ''; //current url target 596 597 ilayer.visibility ='hide'; 598 document.layers[slayer].visibility = 'show'; 599 document.layers[slayer].top = ilayer.top; 600 document.layers[slayer].left = ilayer.left; 601 document.layers[slayer].resizeTo(eval(common_width),eval(common_height)); 602} 603/* Click to new link for NS */ 604function getAction() 605{ 606 if (current_url_status == 'y' && current_page_id != '') //cursor points to page id 607 { 608 window.location.href = current_page_id + '.html'; 609 } 610 else if (current_url_status == 'e' && current_url_name != '') //cursor points to page name 611 { 612 if (current_url_tgt == 'y') // open in new window 613 { 614 window.open(replaceTitletoComma(current_url_name)); 615 getTop(); 616 } 617 else 618 { 619 window.location.href = replaceTitletoComma(current_url_name); 620 } 621 } 622 else if (current_url_status == '' && current_page_id == '' )//cursor has no page id 623 getTop(); 624} // close the function 625 626/* clear all sub navigation */ 627function setClearNSSubLayer(slength) 628{ 629 if(slength > 0) 630 { //starts if - more than one navis 631 for(var i=0;i<main_sub_cat_length;i++) 632 { //starts for loop - run navis 633 // var lay="sub_layer_"+i; 634 var lay = main_sub_cat_arr[i].split(":"); // array layers 635 var layi = lay[1]; //at position 2 636 var layiact = 'act_' + lay[1]; //active layer 637 document.layers[layi].visibility = "hide"; 638 document.layers[layiact].visibility = "hide"; 639 } //close the loop 640 document.layers["bglayer"].visibility = "hide"; 641 } //close if 642} // close the function 643 644/* clear navigation with function overloading */ 645function clearNSSubNavi() 646{ 647 setClearNSSubLayer(main_sub_cat_length); 648} // close the function 649 650function onCurrentNSSubNavis(tar_navis, status, url_name, url_tgt) 651{ 652 current_page_id = tar_navis.substr(8); //current page id 653 current_url_status = status; //current url status 654 current_url_name = url_name; //current url name 655 current_url_tgt = url_tgt; //current url target ( '' / 'n' ) 656 657 for(var i=0;i<f_str_dyn_sub_list.length;i++) 658 { //starts for -1 loop 659 var lay = f_str_dyn_sub_list[i]; //array 660 var layer_active = 'act_' + lay; //array active 661 if(layer_active == tar_navis) 662 { 663 document.layers[lay].visibility = 'hide'; 664 document.layers[layer_active].visibility = 'show'; 665 } 666 else 667 { 668 document.layers[lay].visibility = 'show'; 669 document.layers[layer_active].visibility = 'hide'; 670 } 671 } //close for-1 loop 672} 673/****************************** Close list of NS functions ****************************/ 674 675/****************************** Starts list of IE functions *****************************/ 676/*set sub navigations for dummy operation*/ 677function setIEAllSubNavis() 678{ 679 var l_str_data; //data 680 var properties; //properties 681 var active_layer; //active layer 682 var l_str_arr_single_string;
682 //single string 683 document.write("<div id='subdesktop' style='visibility:hidden;background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='onIEClearSubs()' onMouseout='this.style.visibility=\"hidden\";onIEClearSubs();'> </div>"); 684 document.write("<div id='bglayer' style='visibility:hidden;background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='' onMouseout=''> </div>"); 685 686 for(var i=0;i<main_sub_cat_length;i++) 687 { //starts for loop - run navis 688 properties = main_sub_cat_arr[i].split(':'); 689 active_layer = 'act_'+ properties[1]; 690 l_str_data = ''; 691 l_str_arr_single_string = getNoStrings(properties[2]); 692 var lay_ext = main_sub_cat_ext_arr[i].split("::"); //array 693 for(var k=0;k<l_str_arr_single_string.length;k++) //inner loop - for split indiviual strings from string 694 l_str_data += l_str_arr_single_string[k] + ' '; 695 document.write("<div id='" + properties[1] + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; border-style:outset;border-width:1px; clip:auto; top:535; left:0; height:0; width:0;background-image: url("+open_scroll_img+");' onMouseover='getActiveNavi(\""+ active_layer +"\",this)' onMouseout=''>" + l_str_stable_starts + l_str_data + l_str_table_close + "</div>"); 696 document.write("<div id='" + active_layer + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; border-style:inset;border-width:1px; clip:auto; top:535; left:0; height:0; width:0;background-image: url("+ open_static_img +");' onMouseover='onCurrentIEsubNavis(\"" + active_layer + "\",\"" + properties[3] + "\",\"" + lay_ext[1] + "\",\"" + lay_ext[2] + "\");' onMouseout='getActiveNavi(\""+ properties[1] +"\",this);'>"+ l_str_dtable_starts +l_str_data + l_str_table_close +"</div>"); 697 } //close the for loop 698 clearIENavis(); 699} //close the function 700 701/*set sub navigations for dummy operation*/ 702function setGeckoAllSubNavis() 703{ 704 var l_str_data; //data 705 var properties; //properties 706 var active_layer; //active layer 707 var l_str_arr_single_string; //single string 708 document.write("<div id='subdesktop' style='visibility:hidden;background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='onGeckoClearSubs();onGeckoClearSubsVertical();' onMouseout='this.style.visibility=\"hidden\";onGeckoClearSubs();onGeckoClearSubsVertical();'> </div>"); 709 document.write("<div id='bglayer' style='visibility:hidden;background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='' onMouseout=''> </div>"); 710 711 for(var i=0;i<main_sub_cat_length;i++) 712 { //starts for loop - run navis 713 properties = main_sub_cat_arr[i].split(':'); 714 active_layer = 'act_'+ properties[1]; 715 l_str_data = ''; 716 l_str_arr_single_string = getNoStrings(properties[2]); 717 var lay_ext = main_sub_cat_ext_arr[i].split("::"); //array 718 for(var k=0;k<l_str_arr_single_string.length;k++) //inner loop - for split indiviual strings from string 719 l_str_data += l_str_arr_single_string[k] + ' '; 720 document.write("<div id='" + properties[1] + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; border-style:outset;border-width:1px; clip:auto; top:535; left:0; height:0; width:0;background-image: url("+open_scroll_img+");' onMouseover='getActiveGeckoNavi(\""+ active_layer +"\",this)' onMouseout=''>" + l_str_stable_starts + l_str_data + l_str_table_close + "</div>"); 721 document.write("<div id='" + active_layer + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; border-style:inset;border-width:1px; clip:auto; top:535; left:0; height:0; width:0;background-image: url("+ open_static_img +");' onMouseover='onCurrentGeckosubNavis(\"" + active_layer + "\",\"" + properties[3] + "\",\"" + lay_ext[1] + "\",\"" + lay_ext[2] + "\");' onMouseout='getActiveGeckoNavi(\""+ properties[1] +"\",this);'>"+ l_str_dtable_starts +l_str_data + l_str_table_close +"</div>"); 722 } //close the for loop 723// clearGeckoNavis(); 724} //close the function 725 726function clearIENavis() 727{ 728 for(var i=0;i<main_sub_cat_length;i++) 729 { //starts for loop - run navis 730 properties = main_sub_cat_arr[i].split(':'); 731 active_layer = 'act_' + properties[1]; 732 document.all.item(active_layer).style.visibility = 'hidden'; 733 document.all.item(properties[1]).style.visibility = 'hidden'; 734 } //close the for loop 735 bglayer.style.visibility = 'hidden'; 736} //close the function 737 738function clearGeckoNavis() 739{ 740 for(var i=0;i<main_sub_cat_length;i++) 741 { //starts for loop - run navis 742 properties = main_sub_cat_arr[i].split(':'); 743 active_layer = 'act_' + properties[1]; 744 document.getElementById(active_layer).style.visibility = 'hidden'; 745 document.getElementById(properties[1]).style.visibility = 'hidden'; 746 } //close the for loop 747 document.getElementById('bglayer').style.visibility = 'hidden'; 748} //close the function 749 750function setIESubNavisList(c_cat,index,left,top,height,width) 751{ 752 var l_int_left = left; //left 753 var l_int_top = top; //top 754 clearIENavis(); 755 var l_str_arr_temp = getSubNavisOnly(c_cat); //get acti navis 756 f_str_dyn_sub_list = l_str_arr_temp; 757 var l_int_inc_top = l_int_top; //top 758 var l_int_bg_height = (l_str_arr_temp.length)*(height+1)+Math.round((l_str_arr_temp.length)*(1.5)); //get length 759 var l_int_mheight_inc = 0; 760 for(var n=0;n<l_str_arr_temp.length;n++) 761 { //starts for -1 loop 762 document.all.item(l_str_arr_temp[n]).style.top = l_int_inc_top; 763 document.all.item(l_str_arr_temp[n]).style.left = l_int_left; 764 document.all.item(l_str_arr_temp[n]).style.width = width; 765 document.all.item(l_str_arr_temp[n]).style.height = height; 766 document.all.item(l_str_arr_temp[n]).style.visibility = 'visible'; 767 l_int_inc_top += height + 2; 768 l_int_mheight_inc += height; 769 } //close for-1 loop 770 if(l_str_arr_temp.length > 0) //true-more than zero navis 771 setIEOutsideLayer(l_int_left,l_int_inc_top,width,height,l_int_top,l_int_bg_height); 772} //close the function 773 774function setGeckoSubNavisList(c_cat,index,left,top,height,width) 775{ 776 var l_int_left = left; //left 777 var l_int_top = top; //top 778 clearGeckoNavis(); 779 var l_str_arr_temp = getSubNavisOnly(c_cat); //get acti navis 780 f_str_dyn_sub_list = l_str_arr_temp; 781 var l_int_inc_top = l_int_top; //top 782 var l_int_bg_height = (l_str_arr_temp.length)*(height+1)+Math.round((l_str_arr_temp.length)*(1.5)); //get length 783 var l_int_mheight_inc = 0; 784 for(var n=0;n<l_str_arr_temp.length;n++) 785 { //starts for -1 loop 786 document.getElementById(l_str_arr_temp[n]).style.top = l_int_inc_top; 787 document.getElementById(l_str_arr_temp[n]).style.left = l_int_left; 788 document.getElementById(l_str_arr_temp[n]).style.width = width; 789 document.getElementById(l_str_arr_temp[n]).style.height = height; 790 document.getElementById(l_str_arr_temp[n]).style.visibility = 'visible'; 791 792 document.getElementById('b_'+l_str_arr_temp[n]).style.width = width; 793 document.getElementById('img_'+l_str_arr_temp[n]).style.width = width; 794 795 l_int_inc_top += height + 2; 796 l_int_mheight_inc += height; 797 } //close for-1 loop 798 799 document.getElementById('bglayer').style.width = width; 800 document.getElementById('subdesktop').style.width = width; 801 802 803 804 if(l_str_arr_temp.length > 0) //true-more than zero navis 805 setGeckoOutsideLayer(l_int_left,l_int_inc_top,width,height,l_int_top,l_int_bg_height); 806} //close the function 807 808function getActiveNavi(des_navi_name,curr_navi_object) 809{ 810 current_page_id = ""; 811 current_url_status = ""; 812 current_url_name = ""; //current url for external link 813 current_url_tgt = ""; //current url target 814 815 document.all.item(des_navi_name).style.top = parseInt(curr_navi_object.style.top); 816 document.all.item(des_navi_name).style.left = parseInt(curr_navi_object.style.left); 817 document.all.item(des_navi_name).style.width = parseInt(curr_navi_object.style.width); 818 document.all.item(des_navi_name).style.height = parseInt(curr_navi_object.style.height); 819 curr_navi_object.style.visibility = 'hidden' 820 document.all.item(des_navi_name).style.visibility = 'visible'; 821} // close the function 822 823function getActiveGeckoNavi(des_navi_name,curr_navi_object) 824{ 825 current_page_id = ""; 826 current_url_status = ""; 827 current_url_name = ""; //current url for external link 828 current_url_tgt = ""; //current url target 829 830 document.getElementById(des_navi_name).style.top = parseInt(curr_navi_object.style.top); 831 document.getElementById(des_navi_name).style.left = parseInt(curr_navi_object.style.left); 832 document.getElementById(des_navi_name).style.width = parseInt(curr_navi_object.style.width); 833 document.getElementById(des_navi_name).style.height = parseInt(curr_navi_object.style.height); 834 curr_navi_object.style.visibility = 'hidden' 835 document.getElementById(des_navi_name).style.visibility = 'visible'; 836} // close the function 837 838function whenIEMouseOver(id, url, pos, url_name, url_tgt) 839{ 840 current_page_id = id; 841 current_url_status = url; 842 current_url_name = url_name; //current url name 843 current_url_tgt = url_tgt; //current url target ( '' / 'n' ) 844} //close the function 845function whenIEMouseOut() 846{ 847 current_page_id = ''; 848 current_url_status = ''; 849 current_url_name = ''; //current url for external link 850 current_url_tgt = ''; //current url target 851} //close the function 852 853/*set whenmouseover layer onIE formatted layers */ 854function setIEOutsideLayer(left,top,width,height,default_top,total_height) 855{ 856 bglayer.style.top = default_top-1; 857 bglayer.style.left = left-1; 858 bglayer.style.width = width+2; 859 bglayer.style.height = total_height; 860 bglayer.style.visibility = 'visible'; 861 bglayer.style.background = '#b2b2b2'; 862 863 subdesktop.style.top = default_top - height; 864 if(location_identifier == 'l') 865 subdesktop.style.left = left; //subdesktop.style.left = left - (width/2); 866 else if(location_identifier == 'r') 867 subdesktop.style.left = left-(width/2); 868 else if(vertical_location == 'l') 869 subdesktop.style.left = left; //subdesktop.style.left = left - (width/2); 870 else if(vertical_location == 'r') 871 subdesktop.style.left = left-(width/2); 872 subdesktop.style.width = width + (width/2); 873 subdesktop.style.height = total_height + (height*2); 874 subdesktop.style.visibility = 'visible'; 875// document.all.item('subdesktop').style.background = '#ccc000'; 876} //close the function 877 878function setGeckoOutsideLayer(left,top,width,height,default_top,total_height) 879{ 880 document.getElementById('bglayer').style.top = eval(default_top)-1; 881 document.getElementById('bglayer').style.left = eval(left)-1; 882 document.getElementById('bglayer').style.width = eval(width)+2; 883 document.getElementById('bglayer').style.height = eval(total_height); 884 document.getElementById('bglayer').style.visibility = 'visible'; 885 document.getElementById('bglayer').style.background = '#b2b2b2'; 886 887 document.getElementById('subdesktop').style.top = default_top - height; 888 if(location_identifier == 'l') 889 document.getElementById('subdesktop').style.left = left; //subdesktop.style.left = left - (width/2); 890 else if(location_identifier == 'r') 891 document.getElementById('subdesktop').style.left = left-(width/2); 892 else if(vertical_location == 'l') 893 document.getElementById('subdesktop').style.left = left; //subdesktop.style.left = left - (width/2); 894 else if(vertical_location == 'r') 895 document.getElementById('subdesktop').style.left = left-(width/2); 896 document.getElementById('subdesktop').style.width = width + (width/2); 897 document.getElementById('subdesktop').style.height = total_height + (height*2); 898 document.getElementById('subdesktop').style.visibility = 'visible'; 899// document.getElementById('subdesktop').style.background = '#ccc000'; 900} //close the function 901 902 903function getKeyDown() 904{ 905 906/********** sg16.0 changes ************/ 907 908 909 var l_obj_file_list = sub_navig_file_name.split("::"); 910 var l_str_page_id =""; // get the page i d 911 var l_str_file_name =""; // get the file name 912 var _temp_index =0; 913 var current_file_name =current_page_id + '.html'; 914 for(var i =0; i < l_obj_file_list.length; i++) 915 { 916 l_str_file_name = l_obj_file_list[i]; 917 918 if(l_str_file_name.indexOf(":") >0 ) 919 { 920 _temp_index = l_str_file_name.indexOf(":"); 921 l_str_page_id = l_str_file_name.substring(0,_temp_index); 922 l_str_file_name = l_str_file_name.substring(_temp_index+1,l_str_file_name.length); 923 if(current_page_id == l_str_page_id) 924 current_file_name =l_str_file_name; 925 } 926 } 927 928 929 /********** sg16.0 changes ************/ 930 931 932 if (current_url_status == 'y' && current_page_id != '') //cursor points to page id 933 { 934 location.href = current_file_name; 935 } 936 else if (current_url_status == 'e' && current_url_name != '') //cursor points to page name 937 { 938 if (current_url_tgt == 'y') // open in new window 939 { 940 window.open(replaceTitletoComma(current_url_name)); 941 getTop(); 942 } 943 else 944 { 945 location.href = replaceTitletoComma(current_url_name); 946 } 947 } 948 else if (current_url_status == '' && current_page_id == '') // false - empty 949 { 950 if(_is_gecko_bowser == STR_YES) 951 clearGeckoNavis(); 952 else 953 clearIENavis(); 954 } 955} //close the function 956 957function onCurrentIEsubNavis(tar_navis, status, url_name, url_tgt) 958{ 959 current_page_id = tar_navis.substr(8); 960 current_url_status = status; 961 current_url_name = url_name; //current url name 962 current_url_tgt = url_tgt; //current url target ( '' / 'n' ) 963 964 for(var n=0;n < f_str_dyn_sub_list.length;n++) 965 { //starts for -1 loop 966 var l_str_scroll_layer = 'act_'+ f_str_dyn_sub_list[n]; 967 var l_str_static_layer = f_str_dyn_sub_list[n]; 968 if(tar_navis == l_str_scroll_layer) 969 { 970 document.all.item(l_str_scroll_layer).style.visibility = 'visible'; 971 document.all.item(l_str_static_layer).style.visibility = 'hidden'; 972 } 973 else 974 { 975 document.all.item(l_str_scroll_layer).style.visibility = 'hidden'; 976 document.all.item(l_str_static_layer).style.visibility = 'visible'; 977 } 978 } //close for-1 loop 979} 980 981function onCurrentGeckosubNavis(tar_navis, status, url_name, url_tgt) 982{ 983 current_page_id = tar_navis.substr(8); 984 current_url_status = status; 985 current_url_name = url_name; //current url name 986 current_url_tgt = url_tgt; //current url target ( '' / 'n' ) 987 988 for(var n=0;n < f_str_dyn_sub_list.length;n++) 989 { //starts for -1 loop 990 var l_str_scroll_layer = 'act_'+ f_str_dyn_sub_list[n]; 991 var l_str_static_layer = f_str_dyn_sub_list[n]; 992 if(tar_navis == l_str_scroll_layer) 993 { 994 document.getElementById(l_str_scroll_layer).style.visibility = 'visible'; 995 document.getElementById(l_str_static_layer).style.visibility = 'hidden'; 996 } 997 else 998 { 999 document.getElementById(l_str_scroll_layer).style.visibility = 'hidden'; 1000 document.getElementById(l_str_static_layer).style.visibility = 'visible'; 1001 } 1002 } //close for-1 loop 1003} 1004 1005function onIEClearSubs() 1006{ 1007 for(var n=0;n <f_str_dyn_sub_list.length;n++) 1008 { //starts for -1 loop 1009 var l_str_scroll_layer = 'act_'+ f_str_dyn_sub_list[n]; 1010 var l_str_static_layer = f_str_dyn_sub_list[n]; 1011 document.all.item(l_str_scroll_layer).style.visibility = 'hidden'; 1012 document.all.item(l_str_static_layer).style.visibility = 'hidden'; 1013 } //close for-1 loop 1014 bglayer.style.visibility = 'hidden'; 1015} 1016 1017function onGeckoClearSubs() 1018{ 1019 for(var n=0;n <f_str_dyn_sub_list.length;n++) 1020 { //starts for -1 loop 1021 var l_str_scroll_layer = 'act_'+ f_str_dyn_sub_list[n]; 1022 var l_str_static_layer = f_str_dyn_sub
1022_list[n]; 1023 document.getElementById(l_str_scroll_layer).style.visibility = 'hidden'; 1024 document.getElementById(l_str_static_layer).style.visibility = 'hidden'; 1025 } //close for-1 loop 1026 document.getElementById('bglayer').style.visibility = 'hidden'; 1027} 1028function compareNumbers(a, b) 1029{ 1030 return a - b; 1031} 1032 1033function replaceTitletoComma(externaltext) 1034{ 1035 externaltext = externaltext.replace(/\~~~/g, ","); 1036 return externaltext; 1037} 1038 1039 1040function setGeckoSubNavisListVertical(c_cat,index,left,top) 1041{ 1042 var l_int_left = left; //left 1043 var l_int_top = top; //top 1044 onGeckoClearSubsVertical(); 1045 var l_str_arr_temp = getSubNavisOnly(c_cat); //get acti navis 1046 f_str_dyn_sub_list = l_str_arr_temp; 1047 var l_int_inc_top = l_int_top; //top 1048 var l_int_mheight_inc = 0; 1049 //var width = l_img_width_list[getImageIndex(c_cat)]; 1050 var width = eval(subNavigWidth)+5; 1051 var height = l_img_height; 1052 var l_int_bg_height = (l_str_arr_temp.length)*(height+1) + (l_str_arr_temp.length)*(1.5); //get length 1053 //if(l_scr_total_width > 1024) 1054 //l_int_left1=getSuitXposi(left); 1055 for(var n=0;n<l_str_arr_temp.length;n++) 1056 { //starts for -1 loop 1057 var l_int_snavi_width = width; 1058 var l_int_snavi_left = l_int_left; 1059 var l_int_snavi_total = eval(l_int_left) + eval(width); 1060 document.getElementById(l_str_arr_temp[n]).style.top = l_int_inc_top; 1061 document.getElementById(l_str_arr_temp[n]).style.left = l_int_left; 1062 document.getElementById(l_str_arr_temp[n]).style.width = width; 1063 document.getElementById(l_str_arr_temp[n]).style.height = height; 1064 document.getElementById(l_str_arr_temp[n]).style.visibility = 'visible'; 1065 document.getElementById('b_'+l_str_arr_temp[n]).style.top = l_int_inc_top; 1066 document.getElementById('b_'+l_str_arr_temp[n]).style.left = l_int_left; 1067 document.getElementById('b_'+l_str_arr_temp[n]).style.width = width; 1068 document.getElementById('b_'+l_str_arr_temp[n]).style.height = height; 1069 document.getElementById('b_'+l_str_arr_temp[n]).style.visibility = 'visible'; 1070 document.getElementById('img_'+l_str_arr_temp[n]).style.top = l_int_inc_top; 1071 document.getElementById('img_'+l_str_arr_temp[n]).style.left = l_int_left; 1072 document.getElementById('img_'+l_str_arr_temp[n]).style.width = width; 1073 document.getElementById('img_'+l_str_arr_temp[n]).style.height = height; 1074 document.getElementById('img_'+l_str_arr_temp[n]).style.visibility = 'visible'; 1075 1076 l_int_inc_top += height + 2; 1077 l_int_mheight_inc += height; 1078 } //close for-1 loop 1079 if(l_str_arr_temp.length > 0) //true-more than zero navis 1080 setGeckoOutsideLayerVertical(l_int_left,l_int_inc_top,width,height,l_int_top,l_int_bg_height); 1081} //close the function 1082 1083/*set whenmouseover layer onIE formatted layers */ 1084function setGeckoOutsideLayerVertical(left,top,width,height,default_top,total_height) 1085{ 1086 document.getElementById('bglayer').style.top = default_top - 2; 1087 document.getElementById('bglayer').style.left = left - 2; 1088 document.getElementById('bglayer').style.width = eval(width) + 4; 1089 document.getElementById('bglayer').style.height = total_height + 2; 1090 document.getElementById('bglayer').style.background = '#cccccc'; 1091 document.getElementById('bglayer').style.visibility = 'visible'; 1092 if(horizontal_location =='b' || add_subnavig_type == 'bl' || add_subnavig_type == 'br') 1093 document.getElementById('subdesktop').style.top = default_top - (height+Math.round(height/2)); 1094 else if(horizontal_location =='t') 1095 document.getElementById('subdesktop').style.top = default_top; 1096 1097 var l_int_sdesk_left = left - Math.round(width/4); 1098 document.getElementById('subdesktop').style.left = l_int_sdesk_left; 1099 var l_int_sdesk_width = eval(width) + eval(Math.round(width/2)); 1100 document.getElementById('subdesktop').style.width = l_int_sdesk_width; 1101 if(horizontal_location =='b' || add_subnavig_type == 'bl' || add_subnavig_type == 'br') 1102 document.getElementById('subdesktop').style.height = total_height + (height*2) - Math.round(height/2); 1103 else if(horizontal_location =='t') 1104 document.getElementById('subdesktop').style.height = total_height + (height*2); 1105 1106 var l_max_pixel_left = l_int_sdesk_left + l_int_sdesk_width; 1107 document.getElementById('subdesktop').style.visibility = 'visible'; 1108// document.getElementById('subdesktop').style.background = '#cccccc'; 1109} //close the function 1110 1111function getImageIndex(main_cat) 1112{ 1113 var l_arr_temp_sub = new Array(); 1114 var l_int_count = 0; 1115 var l_int_layer_noofchars = 0; 1116 var l_int_layer_img_index = 0; 1117 if(l_img_scroll_list.length ==3) 1118 { 1119 for(var i=0;i<main_sub_cat_length;i++) 1120 { //starts for loop - 1121 var l_arr_properties = main_sub_cat_arr[i].split(':'); 1122 if(l_arr_properties[0] == main_cat)
1123 l_arr_temp_sub[l_int_count++] = l_arr_properties[2]; 1124 } 1125 for(var j=0;j<l_arr_temp_sub.length;j++) 1126 { //starts for loop - run navis 1127 var l_int_len = l_arr_temp_sub[j].length; 1128 if(l_int_layer_noofchars < l_int_len) 1129 l_int_layer_noofchars = l_int_len; 1130 } 1131 if(l_int_layer_noofchars<8) //if 7chars sub navis 1132 l_int_layer_img_index = 0; 1133 else if(l_int_layer_noofchars<12) 1134 l_int_layer_img_index = 1; 1135 else if(l_int_layer_noofchars>11) 1136 l_int_layer_img_index = 2; 1137 } 1138 else if(l_img_scroll_list.length == 1) 1139 { 1140 l_int_layer_img_index = 0; 1141 } 1142 return l_int_layer_img_index; 1143} 1144 1145function onGeckoClearSubsVertical() 1146{ 1147 for(var n=0;n <f_str_dyn_sub_list.length;n++) 1148 { //starts for -1 loop 1149 var l_str_scroll_layer = 'act_'+ f_str_dyn_sub_list[n]; 1150 var l_str_static_layer = f_str_dyn_sub_list[n]; 1151 var l_str_inamer_scr = 'img_' + l_str_scroll_layer; 1152 var l_str_bname_scr = 'b_' + l_str_scroll_layer; 1153 var l_str_inamer_stc = 'img_' + l_str_static_layer; 1154 var l_str_bname_stc = 'b_' + l_str_static_layer; 1155 1156 document.getElementById(l_str_scroll_layer).style.visibility = 'hidden'; 1157 document.getElementById(l_str_static_layer).style.visibility = 'hidden'; 1158 document.getElementById(l_str_inamer_scr).style.visibility = 'hidden'; 1159 document.getElementById(l_str_inamer_stc).style.visibility = 'hidden'; 1160 document.getElementById(l_str_bname_scr).style.visibility = 'hidden'; 1161 document.getElementById(l_str_bname_stc).style.visibility = 'hidden'; 1162 } //close for-1 loop 1163 document.getElementById('bglayer').style.visibility = 'hidden'; 1164 f_str_dyn_sub_list = new Array(); 1165} 1166 1167/*set sub navigations for gecko's dummy operation*/ 1168function setGeckoAllSubNavisVertical() 1169{ 1170 var l_str_data; //data 1171 var properties; //properties 1172 var active_layer; //active layer 1173 var l_str_arr_single_string; //single string 1174 document.write("<div id='subdesktop' style='visibility:hidden; background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseout='whenIEParamClear();this.style.visibility=\"hidden\";'> </div>"); 1175 document.write("<div id='bglayer' style='visibility:hidden; background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='whenIEParamClear()' onMouseout=''> </div>"); 1176 //document.write("<div id='subdesktop' style='visibility:hidden; background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='onGeckoClearSubs()' onMouseout='whenIEParamClear();this.style.visibility=\"hidden\";onGeckoClearSubs();'> </div>"); 1177 //document.write("<div id='bglayer' style='visibility:hidden; background:transparent; position:absolute; clip:auto; top:0; left:0; height:0; width:0;' onMouseover='whenIEParamClear()' onMouseout=''> </div>"); 1178 1179 //setGeckoAllSubNavis(); 1180 1181 for(var i=0;i<main_sub_cat_length;i++) 1182 { //starts for loop - run navis 1183 properties = main_sub_cat_arr[i].split(':'); 1184 active_layer = 'act_'+ properties[1]; 1185 l_str_data = ''; 1186 l_str_arr_single_string = getNoStrings(properties[2]); 1187 var lay_ext = main_sub_cat_ext_arr[i].split("::"); //array 1188 for(var k=0;k<l_str_arr_single_string.length;k++) //inner loop - for split indiviual strings from string 1189 l_str_data += l_str_arr_single_string[k] + ' '; 1190 1191 var l_img_scroll_value = l_img_scroll_list[getImageIndex(properties[0])]; 1192 var l_img_static_value = l_img_static_list[getImageIndex(properties[0])]; 1193 var l_img_width_value = l_img_width_list[getImageIndex(properties[0])]; 1194 var l_img_height_value = l_img_height; 1195 1196 var l_str_table_1 = "<table width='" + l_img_width_value + "' height='" + l_img_height_value + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='" + l_str_ver_align + "' align='" + title_align + "'><font color='" + default_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 1 1197 var l_str_table_0 = "<table width='" + l_img_width_value + "' height='" + l_img_height_value + "' border='0' cellspacing='0' cellpadding='0'><tr><td valign='" + l_str_ver_align + "' align='"+ title_align +"'><font color='" + scroll_title_color + "' face='" + title_style + "' class='titlesize'> "; //starts table 2 1198 var l_str_table_00 = " </font></td></tr></table>"; //close the table 1199 1200 document.write("<div id='img_" + properties[1] + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:1;' onMouseover='' onMouseout=''><img src='"+ l_img_static_value +"' height="+l_img_height_value+" width="
1200+ l_img_width_value + " alt='sample'></div>"); 1201 document.write("<div id='" + properties[1] + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:2;overflow:hidden;background-image: url("+open_scroll_img+");' onMouseover='getActiveGeckoNavi(\""+ active_layer +"\",this)' onMouseout=''>" + l_str_table_0 + l_str_data + l_str_table_00 + "</div>"); 1202 1203 document.write("<div id='b_" + properties[1] + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:3;' onMouseover='getGeckoActiveNavi(\""+properties[1]+"\",\""+ active_layer +"\",this)' onMouseout=''>" + l_str_table_1 +"" + l_str_table_00 + "</div>"); 1204 1205 document.write("<div id='img_" + active_layer + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:1;' onMouseover='' onMouseout=''><img src='"+ l_img_scroll_value +"' height="+l_img_height_value+" width=" + l_img_width_value +" alt='sample'></div>"); 1206 document.write("<div id='" + active_layer + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:2;overflow:hidden;background-image: url("+ open_static_img +");' onMouseover='onCurrentGeckosubNavis(\"" + active_layer + "\",\"" + properties[3] + "\",\"" + lay_ext[1] + "\",\"" + lay_ext[2] + "\");' onMouseout='getActiveGeckoNavi(\""+ properties[1] +"\",this);'>"+ l_str_table_1 +l_str_data + l_str_table_00 +"</a></div>"); 1207 document.write("<div id='b_" + active_layer + "' style=' " +cursorType+" visibility:hidden; background:transparent; position:absolute; clip:auto; top:535; left:0; height:0; width:0;z-index:3;' onMouseover='onCurrentGeckosubNavis(\"" + active_layer + "\",\"" + properties[3] + "\",\"" + lay_ext[1] + "\",\"" + lay_ext[2] + "\");' onMouseout='getGeckoActiveNavi(\""+active_layer+"\",\""+ properties[1] +"\",this);'>"+ l_str_table_1 +"" + l_str_table_00 +"</div>"); 1208 } //close the for loop 1209 1210 1211// clearGeckoNavis(); 1212} //close the function 1213 1214function whenIEParamClear() 1215{ 1216 current_page_id = ''; 1217 current_url_status = ''; 1218 current_url_name = ''; //current url for external link 1219 current_url_tgt = ''; //current url target 1220} 1221 1222function getGeckoActiveNavi(curr_navi_name,des_navi_name,curr_navi_object) 1223{ 1224 var des_navi_blk_name = 'b_' + des_navi_name; 1225 var des_navi_img_name = 'img_' + des_navi_name; 1226 var cur_navi_img_name = 'img_' + curr_navi_name; 1227 1228 document.getElementById(des_navi_name).style.top = parseInt(curr_navi_object.style.top); 1229 document.getElementById(des_navi_name).style.left = parseInt(curr_navi_object.style.left); 1230 document.getElementById(des_navi_name).style.width = parseInt(curr_navi_object.style.width); 1231 document.getElementById(des_navi_name).style.height = parseInt(curr_navi_object.style.height); 1232 document.getElementById(des_navi_name).style.visibility = 'visible'; 1233 1234 document.getElementById(des_navi_blk_name).style.top = parseInt(curr_navi_object.style.top); 1235 document.getElementById(des_navi_blk_name).style.left = parseInt(curr_navi_object.style.left); 1236 document.getElementById(des_navi_blk_name).style.width = parseInt(curr_navi_object.style.width); 1237 document.getElementById(des_navi_blk_name).style.height = parseInt(curr_navi_object.style.height); 1238 document.getElementById(des_navi_blk_name).style.visibility = 'visible'; 1239 1240 document.getElementById(des_navi_img_name).style.top = parseInt(curr_navi_object.style.top); 1241 document.getElementById(des_navi_img_name).style.left = parseInt(curr_navi_object.style.left); 1242 document.getElementById(des_navi_img_name).style.width = parseInt(curr_navi_object.style.width); 1243 document.getElementById(des_navi_img_name).style.height = parseInt(curr_navi_object.style.height); 1244 document.getElementById(des_navi_img_name).style.visibility = 'visible'; 1245 1246 curr_navi_object.style.visibility = 'hidden' 1247 document.getElementById(curr_navi_name).style.visibility = 'hidden'; 1248 document.getElementById(cur_navi_img_name).style.visibility = 'hidden'; 1249} // close the function 1250 1251//Hiding sub navigation displayed 1252function hideSubNavig() 1253{ 1254 var l_str_arr_temp = getSubNavisOnly(currentCat); //get acti navis 1255 for(var n=0;n<l_str_arr_temp.length;n++) 1256 { //starts for -1 loop 1257 1258 document.getElementById(l_str_arr_temp[n]).style.visibility = 'hidden'; 1259 if(_is_gecko_bowser == STR_YES) 1260 { 1261 document.getElementById('b_'+l_str_arr_temp[n]).style.visibility = 'hidden'; 1262 document.getElementById('img_'+l_str_arr_temp[n]).style.visibility = 'hidden'; 1263 } 1264 } //close for-1 loop 1265 1266 document.getElementById('bglayer').style.visibility = 'hidden'; 1267 document.getElementById('subdesktop').style.visibility = 'hidden'; 1268} 1269 1270function hidePrevSubNavig(cat_id) 1271{ 1272 var l_str_arr_temp = getSubNavisOnly(cat_id); //get acti navis 1273 for(var n=0;n<l_str_arr_temp.length;n++) 1274 { //starts for -1 loop 1275 1276 document.getElementById(l_str_arr_temp[n]).style.visibility = 'hidden'; 1277 if(_is_gecko_bowser == STR_YES) 1278 { 1279 document.getElementById('b_'+l_str_arr_temp[n]).style.visibility = 'hidden'; 1280 document.getElementById('img_'+l_str_arr_temp[n]).style.visibility = 'hidden'; 1281 } 1282 } //close for-1 loop 1283 1284 document.getElementById('bglayer').style.visibility = 'hidden'; 1285 document.getElementById('subdesktop').style.visibility = 'hidden'; 1286} 1287 1288if(_is_gecko_bowser == STR_YES) 1289{ 1290//clicking on the document, initiate method for hiding sub navigation displayed 1291 document.addEventListener("mousedown", hideSubNavig, false); 1292}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.