1$mode='dev'; 2 3(function ($, window) { 4 5 6 7 $.fn.contextMenu = function (settings) { 8 9 10 11 return this.each(function () { 12 13 14 15 $(this).on("contextmenu", function (e) { 16 17 //open menu 18 19 var $menu = $(settings.menuSelector) 20 21 .data("invokedOn", $(e.target)) 22 23 .show() 24 25 .css({ 26 27 position: "absolute", 28 29 left: getMenuPosition(e.clientX, 'width', 'scrollLeft'), 30 31 top: getMenuPosition(e.clientY, 'height', 'scrollTop') 32 33 }) 34 35 .off('click') 36 37 .on('click', 'a', function (e) { 38 39 $menu.hide(); 40 41 42 43 var $invokedOn = $menu.data("invokedOn"); 44 45 var $selectedMenu = $(e.target); 46 47 48 49 settings.menuSelected.call(this, $invokedOn, $selectedMenu); 50 51 }); 52 53 54 55 return false; 56 57 }); 58 59 60 61 //make sure menu closes on any click 62 63 $(document).click(function () { 64 65 $(settings.menuSelector).hide(); 66 67 }); 68 69 }); 70 71 72 73 function getMenuPosition(mouse, direction, scrollDir) { 74 75 var win = $(window)[direction](), 76 77 scroll = $(window)[scrollDir](), 78 79 menu = $(settings.menuSelector)[direction](), 80 81 position = mouse + scroll; 82 83 84 85 // opening menu would pass the side of the page 86 87 if (mouse + menu > win && menu < mouse) 88 89 position -= menu; 90 91 92 93 return position; 94 95 } 96 97 98 99 }; 100 101})(jQuery, window); 102 103 104 105 106 107jQuery(function ($) { 108 109 $.noConflict(); 110 111 112 113 var headerHight = 300; 114 115 var fragment=window.location.hash; 116 117 $loadTimeOut=10000; 118 119 $autoP=true; 120 121 122 123 //jQuery('#preLoader, header>.modal-backdrop').addClass('opacity05'); 124 125 jQuery('#preLoader, header>.modal-backdrop').removeClass('show').hide(); 126 127 function getCurrentScroll() { 128 129 return window.pageYOffset || document.documentElement.scrollTop; 130 131 } 132 133 134 135 function shrinkHeader(sc) { 136 137 if (sc >= headerHight) { 138 139 $('.header').addClass('shrink'); 140 141 } else { 142 143 $('.header').removeClass('shrink'); 144 145 } 146 147 } 148 149 150 151 function checkSession(){ 152 153 if (sessionStorage.getItem('dontShowModal') !== 'true') { 154 155 //console.log("Displaying modal"); 156 157 return false; 158 159 }else{ 160 161 //console.log("Modal not displaying"); 162 163 return true; 164 165 } 166 167 } 168 169 170 171 function handleError(type, msg) { 172 173 if (type == "s") { 174 175 $(".alert") 176 177 .append("<span class='appended'>" + msg + "</span>") 178 179 .attr('class', 'alert alert-success fade show in') 180 181 .find('strong').html('Success!'); 182 183 } else { 184 185 $(".alert") 186 187 .append("<span class='appended'>" + msg + "</span>") 188 189 .attr('class', 'alert alert-danger fade show in') 190 191 .find('strong').html('Error!'); 192 193 } 194 195 window.setTimeout(function () { 196 197 $(".alert") 198 199 .attr('class', 'alert alert-danger fade') 200 201 .find('.appended').remove(); 202 203 }, 5000); 204 205 } 206 207 208 209 var scroll = getCurrentScroll(); 210 211 shrinkHeader(scroll); 212 213 214 215 $('.incl').each(function(){ 216 217 $this=$(this); 218 219 if($.trim($this.html())!==""){ 220 221 $this.removeClass('incl'); 222 223 } 224 225 }); 226 227 if($mode=="prod" && $mode!="dev"){ 228 229 $(document).on('keydown',function(e) { 230 231 if(event.keyCode == 123) { 232 233 return false; 234 235 } 236 237 if(e.ctrlKey && e.shiftKey && e.keyCode == 'I'.charCodeAt(0)){ 238 239 return false; 240 241 } 242 243 if(e.ctrlKey && e.shiftKey && e.keyCode == 'J'.charCodeAt(0)){ 244 245 return false; 246 247 } 248 249 if(e.ctrlKey && e.keyCode == 'U'.charCodeAt(0)){ 250 251 return false; 252 253 } 254 255 }).contextMenu({ 256 257 menuSelector:$("#contextMenu") 258 259 }); 260 261 } 262 263 if(($('#showAnnounceCenter').length>0) && (!checkSession())){ 264 265 $('#showAnnounceCenter').modal('show'); 266 267 $('section#ticker').append($('body>.modal-backdrop.show').detach()).css('z-index',"1041"); 268 269 $('#showAnnounceCenter').on('shown.bs.modal', function (e) { 270 271 $('#showLater').focus(); 272 273 }).on('hide.bs.modal', function (e) { 274 275 $('section#ticker').css('z-index',"1028"); 276 277 }); 278 279 280 281 $('#showAnnounceCenter button').on('click',function(e){ 282 283 var id=e.target.id; 284 285 if(id!=="" && id=="dontShow"){ 286 287 sessionStorage.setItem('dontShowModal','true'); 288 289 }else{ 290 291 sessionStorage.setItem('dontShowModal','false'); 292 293 } 294 295 }); 296 297 298 299 $('.announcemodal>li a').on('click',function(e){ 300 301 sessionStorage.setItem('dontShowModal','true'); 302 303 }); 304 305 306 307 } 308 309 310 311 $('#sitemapNav li a').on('click',function(e) { 312 313 e.preventDefault(); 314 315 var $sec=$(this).attr("href"); 316 317 var $col=$($sec).parent(".cols"); 318 319 $('#sitemapNav li a').removeClass('active'); 320 321 $('.cols').removeClass('active'); 322 323 $(this).addClass('active'); 324 325 $col.addClass('active'); 326 327 }); 328 329 330 331 setTimeout(function(){ 332 333 if($(".incl").length>0){ 334 335 $(".incl").removeClass("incl").addClass("incl-error") 336 337 } 338 339 }, $loadTimeOut); 340 341 342 343 $('#home #mainNavbar li').on('click',function(){ 344 345 $('nav.homepage #mainNavbar li').removeClass('active'); 346 347 $(this).addClass('active'); 348 349 }); 350 351 352 353 $(document).click(function (event) { 354 355 var clickover = $(event.target); 356 357 var _opened = $(".navbar-collapse.show"); 358 359 var _hasclass = _opened.hasClass("show"); 360 361 if (_hasclass === true && !clickover.hasClass("navbar-toggler")) { 362 363 _opened.siblings(".navbar-toggler").click(); 364 365 } 366 367 }); 368 369 370 371 if($('#controlSet').length>0){ 372 373 $("#controlSet>*").on('click',function(e) { 374 375 e.preventDefault(); 376 377 $id=e.currentTarget.id; 378 379 if($id=='gb'){ 380 381 window.history.back(); 382 383 } 384 385 if($id=='gh'){ 386 387 window.location="./"; 388 389 } 390 391 if($id=='vf'){ 392 393 $("#previewCont").addClass('animated slideInRight'); 394 395 } 396 397 if($id=='df'){ 398 399 window.location="incl/download.php?file="+$("#fname").val(); 400 401 } 402 403 }); 404 405 } 406
407 if($('#info-tab .dfile').length>0){ 408 409 $("a.dfile").on('click',function(e) { 410 411 e.preventDefault(); 412 413 $this=$(this); 414 415 $path=$(this).find("input.fname").val(); 416 417 window.location="incl/download.php?file="+$path; 418 419 }); 420 421 } 422 423 424 425 if($('#social').length>0){ 426 427 $(window).on("load resize", function(){ 428 429 setTimeout(function() { 430 431 var container_width = $('#social').width(); 432 433 $('#social').html('<div class="fb-page" ' + 434 435 'data-href="https://www.facebook.com/BISEMDNOfficial/"' + 436 437 ' data-width="' + container_width + '" data-tabs="timeline" data-small-header="true" data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="true"><div class="fb-xfbml-parse-ignore"><blockquote cite="https://www.facebook.com/BISEMDNOfficial/"><a href="https://www.facebook.com/BISEMDNOfficial/">Auto*Mat</a></blockquote></div></div>'); 438 439 FB.XFBML.parse( ); 440 441 }, 100); 442 443 }); 444 445 } 446 447 448 449 function getURLParameter(url, name) { 450 451 return (RegExp(name + '=' + '(.+?)(&|$)').exec(url)||[,null])[1]; 452 453 } 454 455 456 457 $("div.service-tab-menu>div.list-group>a[href^='#']").click(function (e) { 458 459 e.preventDefault(); 460 461 $(this).siblings('a.active').removeClass("active"); 462 463 $(this).addClass("active"); 464 465 var index = $(this).index(); 466 467 $(".service-tab-content").removeClass("active"); 468 469 $(".service-tab-content").eq(index).addClass("active"); 470 471 }); 472 473 474 475 $(window).on('scroll', function () { 476 477 if ($(this).scrollTop() > 600) { 478 479 $('.scrollup').fadeIn(); 480 481 } else { 482 483 $('.scrollup').fadeOut(); 484 485 } 486 487 scroll = getCurrentScroll(); 488 489 shrinkHeader(scroll); 490 491 }); 492 493 494 495 $('.scrollup').on('click', function () { 496 497 $("html, body").animate({ 498 499 scrollTop: 0 500 501 }, 1000); 502 503 return false; 504 505 }); 506 507 508 509 $(".animatedNav a[href^='#']").on('click', function (e) { 510 511 e.preventDefault(); 512 513 var target = this.hash; 514 515 $('.temp').removeClass('scrolled'); 516 517 $(target).addClass('scrolled temp'); 518 519 $('html, body').animate({ 520 521 scrollTop: $(target).offset().top 522 523 }, 600, function () { 524 525 window.location.hash = target; 526 527 }); 528 529 530 531 }); 532 533 534 535 if(fragment!=""){ 536 537 var target = fragment; 538 539 $('.temp').removeClass('scrolled'); 540 541 $(target).addClass('scrolled temp'); 542 543 $('html, body').animate({ 544 545 scrollTop: $(target).offset().top 546 547 }, 600, function () { 548 549 window.location.hash = target; 550 551 }); 552 553 } 554 555 556 557 if ($('#ticker').length > 0) { 558 559 $(".announcebox").bootstrapNews({ 560 561 newsPerPage: 1, 562 563 pauseOnHover: true, 564 565 autoplay: $autoP 566 567 }); 568 569 } 570 571 572 573 if ($('#events').length > 0) { 574 575 $(".events").bootstrapNews({ 576 577 newsPerPage: 1, 578 579 pauseOnHover: true, 580 581 autoplay: false 582 583 }); 584 585 } 586 587 588 589 //News and datesheets widget 590 591 if ($('.notificationbox').length > 0) { 592 593 var intitNews = false, 594 595 initSheet = false;
596 597 $(".notificationbox").bootstrapNews({ 598 599 newsPerPage: 5, 600 601 pauseOnHover: true, 602 603 autoplay: $autoP 604 605 }); 606 607 } 608 609 610 611 $('.nav-tabs a.con').on('shown.bs.tab', function (event) { 612 613 if (!initSheet) { 614 615 $(".datesheets").bootstrapNews({ 616 617 newsPerPage: 5, 618 619 pauseOnHover: true, 620 621 autoplay: $autoP 622 623 }); 624 625 initSheet = true; 626 627 } 628 629 }); 630 631 $('.nav-tabs a.new').on('shown.bs.tab', function (event) { 632 633 if (!intitNews) { 634 635 $(".newsbox").bootstrapNews({ 636 637 newsPerPage: 5, 638 639 pauseOnHover: true, 640 641 autoplay: $autoP 642 643 }); 644 645 intitNews = true; 646 647 } 648 649 }); 650 651 652 653 if ($('.wow').length > 0) { 654 655 //Initiat WOW JS 656 657 new WOW().init(); 658 659 } 660 661 662 663 // notification filter 664 665 if ($('.notification-items').length > 0) { 666 667 'use strict'; 668 669 var $notification_selectors = $('.notification-filter >li>a'); 670 671 var $notification = $('.notification-items'); 672 673 $notification.isotope({ 674 675 itemSelector: '.notification-item', 676 677 layoutMode: 'fitRows' 678 679 }); 680 681 682 683 $notification_selectors.on('click', function () { 684 685 $notification_selectors.removeClass('active'); 686 687 $(this).addClass('active'); 688 689 var selector = $(this).attr('data-filter'); 690 691 $notification.isotope({ 692 693 filter: selector 694 695 }); 696 697 return false; 698 699 }); 700 701 702 703 704 705 var filterFns = { 706 707 // show if name ends with -ium 708 709 doSearch: function (val) { 710 711 //var name = $(this).find('h4').html(); 712 713 console.log("test " + val); 714 715 //return name.match(/'+val+'/); 716 717 } 718 719 }; 720 721 722 723 } 724 725 726 727 if ($("a[rel^='prettyPhoto']").length > 0) { 728 729 //Pretty Photo 730 731 $("a[rel^='prettyPhoto']").prettyPhoto({ 732 733 social_tools: false 734 735 }); 736 737 } 738 739 740 741 if ($("#main-contact-form").length > 0) { 742 743 $.validate({ 744 745 modules: 'security', 746 747 onModulesLoaded: function () { 748 749 $('#message').restrictLength($('#maxlength')); 750 751 } 752 753 }); 754 755 756 757 $("#main-contact-form").submit(function (e) { 758 759 var data = $(this).serializeArray(); 760 761 $.ajax({ 762 763 type: "POST", 764 765 url: '../scripts/contact.php', 766 767 data: data, 768 769 success: function (resp) { 770 771 if ($.trim(resp) === "success") { 772 773 handleError("s", "Thank you for contacting us. We will be in touch with you very soon!"); 774 775 } else { 776 777 handleError("e", resp); 778 779 } 780 781 } 782 783 }); 784 785 e.preventDefault(); 786 787 }); 788 789 } 790 791}); 792 793 794 795jQuery(window).on('load',function(){ 796 797 jQuery('#preLoader, header>.modal-backdrop').removeClass('show').hide(); 798 799}) 800
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.