1// Call this and pass video file to play in JW 2function loadVideo(myFile, title, desc) { 3 jwplayer().load([{ 4 file: myFile, 5 //image: myImage 6 }]); 7 jwplayer().play(); 8 jwplayer().setMute(false); 9 10 if(title != null) 11 { 12 $("#myModalLabel").html(title); 13 } 14 if(desc != null && desc != "") 15 { 16 $("#video-description").html(desc); 17 $("#video-description").css("display", "block"); 18 $("#video-description").css("margin-top", "20px"); 19 } 20 else 21 { 22 $("#video-description").html(""); 23 $("#video-description").css("display", "hidden"); 24 $("#video-description").css("margin-top", "0px"); 25 } 26}; 27 28$(document).ready(function(e) { 29 30 31 if (navigator.userAgent.match(/MSIE 8/) !== null) { 32 // IE 8 33 $.getScript("http://jwpsrv.com/library/cerj4DvmEeOnIiIACqoGtw.js", function(){ 34 // jwplayer setup 35 //jwplayer.key="+97nu9zwpufEyerLhDMZ7xO7a1qrWOwSugjEIQ=="; 36 jwplayer("banner").setup({ 37 image: "test", 38 file: "Client films/5LM_Showreel_2016_FIN.mp4", 39 width:"100%", 40 height:"100%", 41 fallback: true, 42 mute: false, 43 autostart: false 44 }); 45 46 }); 47 } 48 else 49 { 50 $.getScript("jwplayer7/jwplayer.js", function(){ 51 // jwplayer setup 52 jwplayer.key="uQRGlqJw+8pnUmFf1P0J/m5m1KsjD1wQJowrMA=="; 53 54 jwplayer("banner").setup({ 55 image: "test", 56 file: "Client films/5LM_Showreel_2016_FIN.mp4", 57 width:"100%", 58 height:"100%", 59 fallback: true, 60 mute: false, 61 autostart: false, 62 aspectratio:"16:9" 63 }); 64 }); 65 } 66 67 // stop video on modal close 68 $('#myModal').on('hide.bs.modal', function () 69 { 70 jwplayer().stop(); 71 }) 72 $("a[href^=#]").click(function(e) { e.preventDefault(); var dest = $(this).attr('href'); if(dest != "#" && dest !="#myCarousel"){ $('html,body').animate({ scrollTop: $(dest).offset().top }, 'slow'); } }); 73 74 // hide #back-top first 75 $("#back-top").hide(); 76 $("#bottom-strip").hide(); 77 78 // fade in #back-top 79 $(function () { 80 $(window).scroll(function () { 81 if ($(this).scrollTop() > 100) { 82 $('#back-top').fadeIn(); 83 $('#bottom-strip').fadeIn(); 84 $("#back-top").css("margin-right", "15px"); 85 } else { 86 $('#back-top').fadeOut(); 87 $('#bottom-strip').fadeOut(); 88 } 89 }); 90 91 // scroll body to 0px on click 92 $('#back-top a').click(function () { 93 $('body,html').animate({ 94 scrollTop: 0 95 }, 800); 96 return false; 97 }); 98 }); 99 100 // Randomize Film image 101 rn = Math.ceil(Math.random() * 3); 102 img = "images/film-" + rn.toString() + ".jpg"; 103 $("#film-img").attr("src", img); 104 105 rn = Math.ceil(Math.random() * 3); 106 img = "images/3d-" + rn.toString() + ".jpg"; 107 $("#3d-img").attr("src", img); 108 109 rn = Math.ceil(Math.random() * 4); 110 img = "images/ivt-" + rn.toString() + ".jpg"; 111 $("#ivt-img").attr("src", img); 112 113 114 115 116 117 /* 118 Set clients grid 119 lg - 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 120 md - 1, 2, 7, 8, 3, 4, 9, 10, 5, 6, 11, 12 121 sm - 1, 3, 5, 2, 4, 6, 7, 9, 11, 8, 10, 12 122 xs - 1, 2, 7, 8, 3, 4, 9, 10, 5, 6, 11, 12 123 */ 124 $(window).on("resize", function() 125 { 126 var clientsContent = $("<div id=\"updated-clients\" />"); 127 128 if(window.innerWidth > 1196) 129 { 130 clientsContent 131 .append($("#client-1")) 132 .append($("#client-2")) 133 .append($("#client-3")) 134 .append($("#client-4")) 135 .append($("#client-5")) 136 .append($("#client-6")) 137 .append($("#client-7")) 138 .append($("#client-8")) 139 .append($("#client-9")) 140 .append($("#client-10")) 141 .append($("#client-11")) 142 .append($("#client-12")); 143 } 144 else if(window.innerWidth > 960) 145 { 146 clientsContent 147 .append($("#client-1")) 148 .append($("#client-2")) 149 .append($("#client-7")) 150 .append($("#client-8")) 151 .append($("#client-3")) 152 .append($("#client-4")) 153 .append($("#client-9")) 154 .append($("#client-10")) 155 .append($("#client-5")) 156 .append($("#client-6")) 157 .append($("#client-11")) 158 .append($("#client-12")); 159 } 160 else if(window.innerWidth > 724) 161 { 162 clientsContent 163 .append($("#client-1")) 164 .append($("#client-3")) 165 .append($("#client-5")) 166 .append($("#client-2")) 167 .append($("#client-4")) 168 .append($("#client-6")) 169 .append($("#client-7")) 170 .append($("#client-9")) 171 .append($("#client-11")) 172 .append($("#client-8")) 173 .append($("#client-10")) 174 .append($("#client-12")); 175 } 176 else if(window.innerWidth > 488) 177 { 178 clientsContent 179 .append($("#client-1")) 180 .append($("#client-2")) 181 .append($("#client-7")) 182 .append($("#client-8")) 183 .append($("#client-3")) 184 .append($("#client-4")) 185 .append($("#client-9")) 186 .append($("#client-10")) 187 .append($("#client-5")) 188 .append($("#client-6")) 189 .append($("#client-11")) 190 .append($("#client-12")); 191 } 192 else if(window.innerWidth <= 488) 193 { 194 clientsContent 195 .append($("#client-1")) 196 .append($("#client-2")) 197 .append($("#client-7")) 198 .append($("#client-8")) 199 .append($("#client-3")) 200 .append($("#client-4")) 201 .append($("#client-9")) 202 .append($("#client-10")) 203 .append($("#client-5")) 204 .append($("#client-6")) 205 .append($("#client-11")) 206 .append($("#client-12")); 207 } 208 else 209 { 210 clientsContent 211 .append($("#client-1")) 212 .append($("#client-2")) 213 .append($("#client-3")) 214 .append($("#client-4")) 215 .append($("#client-5")) 216 .append($("#client-6")) 217 .append($("#client-7")) 218 .append($("#client-8")) 219 .append($("#client-9")) 220 .append($("#client-10")) 221 .append($("#client-11")) 222 .append($("#client-12")); 223 } 224 225 226 $(".clients-row").html(clientsContent); 227 228
229 if(!isClipPathSupported() || isAppleDevice()) 230 { 231 //console.log("In apple 1"); 232 $("#carousel-item-4").css("background-image", "url('../images/Banners/Banner NHS WireRender.jpg') no-repeat 65%"); 233 //console.log("In apple 2"); 234 $("#carousel-item-5").css("background-image", "url('../images/Banners/Banner NHS WireRender.jpg') no-repeat 65%"); 235 //console.log("In apple 3"); 236 } 237 if(!isClipPathSupported() || isAppleDevice()) 238 { 239 $("#carousel-item-1").css("background-image", "url('../images/Banners/Banners NR Head Mid.jpg') no-repeat 65%"); 240 $("#carousel-item-6").css("background-image", "url('../images/Banners/Banners NR Head Mid.jpg') no-repeat 65%"); 241 } 242 243 }).resize(); 244 245 246 $('.carousel').carousel({ 247 pause: "false" 248 }); 249 250 $('#myCarousel').on('slid.bs.carousel', function () { 251 252 clearTimeout(t); 253 254 255 $('.active').each(function(i, e){ 256 var duration = $(this).attr('data-interval'); 257 258 $('#myCarousel').carousel('pause'); 259 t = setTimeout("$('#myCarousel').carousel();", duration-1000); 260 $(".ambulance-clipped").css("transition", "none"); 261 $(".ambulance-clipped").css("-webkit-clip-path", "polygon(0px 100%,0% 100%,0% 0px,0px 0px)"); 262 263 if($(this).attr("id") == 'carousel-item-4'){ 264 clearTimeout(ambTO1); 265 clearTimeout(ambTO2); 266 clearTimeout(ambTO3); 267 $(".ambulance-clipped").css("transition", "none"); 268 $(".ambulance-clipped").css("-webkit-clip-path", "polygon(0px 100%,0% 100%,0% 0px,0px 0px)"); 269 270 ambTO1 = setTimeout(doAmbulance, 1500); 271 } 272 273 if($(this).attr("id") == 'carousel-item-1'){ 274 clearTimeout(nrTO1); 275 clearTimeout(nrTO2); 276 clearTimeout(nrTO3); 277 $(".ambulance-clipped").css("transition", "none"); 278 $(".ambulance-clipped").css("-webkit-clip-path", "polygon(0px 100%,0% 100%,0% 0px,0px 0px)"); 279 280 nrTO1 = setTimeout(doAmbulance, 1500); 281 } 282 283 284 }); 285 }); 286 287 288 var t; 289 290 var start = $('#myCarousel').find('.active').attr('data-interval'); 291 t = setTimeout("$('#myCarousel').carousel({interval: 1000});", start-1000); 292 293 $('.carousel-control.right').on('click', function(){ 294 clearTimeout(t); 295 }); 296 297 $('.carousel-control.left').on('click', function(){ 298 clearTimeout(t); 299 }); 300 301}); 302 303var ambTO1; 304var ambTO2; 305var ambTO3; 306 307var nrTO1; 308var nrTO2; 309var nrTO3; 310 311function doAmbulance() 312{ 313 $(".ambulance-clipped").css("transition", "all 3s linear"); 314 $(".ambulance-clipped").css("-webkit-clip-path", "polygon(0px 100%, 80% 100%, 100% 0px,0px 0px)"); 315} 316 317 318function isMobile() { 319 try{ document.createEvent("TouchEvent"); return true; }
320 catch(e){ return false; } 321} 322// Copyright 2014-2015 Twitter, Inc. 323// Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 324if (navigator.userAgent.match(/IEMobile\/10\.0/)) { 325 var msViewportStyle = document.createElement('style') 326 msViewportStyle.appendChild( 327 document.createTextNode( 328 '@-ms-viewport{width:auto!important}' 329 ) 330 ) 331 document.querySelector('head').appendChild(msViewportStyle) 332} 333 334function isAppleDevice() { 335 return ( 336 (navigator.userAgent.toLowerCase().indexOf("ipad") > -1) || 337 (navigator.userAgent.toLowerCase().indexOf("iphone") > -1) || 338 (navigator.userAgent.toLowerCase().indexOf("ipod") > -1) 339 ); 340} 341 342 343 344var isClipPathSupported = function () { 345 346 var base = 'clipPath', 347 prefixes = [ 'webkit', 'moz', 'ms', 'o' ], 348 properties = [ base ], 349 testElement = document.createElement( 'testelement' ), 350 attribute = 'polygon(50% 0%, 0% 100%, 100% 100%)'; 351 352 // Push the prefixed properties into the array of properties. 353 for ( var i = 0, l = prefixes.length; i < l; i++ ) { 354 var prefixedProperty = prefixes[i] + base.charAt( 0 ).toUpperCase() + base.slice( 1 ); // remember to capitalize! 355 properties.push( prefixedProperty ); 356 } 357 358 // Interate over the properties and see if they pass two tests. 359 for ( var i = 0, l = properties.length; i < l; i++ ) { 360 var property = properties[i]; 361 362 // First, they need to even support clip-path (IE <= 11 does not)... 363 if ( testElement.style[property] === '' ) { 364 365 // Second, we need to see what happens when we try to create a CSS shape... 366 testElement.style[property] = attribute; 367 if ( testElement.style[property] !== '' ) { 368 return true; 369 } 370 } 371 } 372 373 return false; 374}; 375 376function initialize() 377{ 378 var myLatlng = new google.maps.LatLng(52.92324, -1.49184 ); 379 var mapOptions = { 380 center: new google.maps.LatLng(52.92424, -1.49184), 381 zoom: 15, 382 scrollwheel: false, 383 draggable: false 384 }; 385 var map = new google.maps.Map(document.getElementById("map_canvas"), 386 mapOptions); 387 var sMapText = "<span style='color: black; margin: 0; padding: 0; '><strong>5 Lamps Media Ltd<\/strong><br />" + 388 "3 Woburn House<br />" + 389 "Vernon Gate<br />" + 390 "Derby<br />" + 391 "DE1 1UL<br />" + 392 "Tel: 01332 383322<br />" + 393 "Email: <a style='color: blue; ' href='mailt"+"o:m"+ 394 "a"+"il"+"@5la"+"mps"+".c"+"om' title='Email 5 Lamps Media'>m"+ 395 "a"+"il"+"@5la"+"mps"+".c"+"om<\/a><br />" + 396 "Web: <a style='color: blue; 'href='http://www.5lamps.com'>http://www.5lamps.com<\/a><\/span>"; 397 398 var infowindow = new google.maps.InfoWindow({ 399 content: sMapText 400 }); 401 402 // To add the marker to the map, use the 'map' property 403 var marker = new google.maps.Marker({ 404 position: myLatlng, 405 map: map, 406 title:"5 Lamps Media Ltd" 407 }); 408 409 infowindow.open(map,marker); 410 411 google.maps.event.addListener(marker, 'click', function() { 412 infowindow.open(map,marker); 413 }); 414 google.maps.event.addListener(map, 'click', function(event){ 415 this.setOptions({scrollwheel:true, draggable: true }); 416 }); 417 google.maps.event.addListener(map, 'mouseout', function(event){ 418 this.setOptions({scrollwheel:false, draggable: false }); 419 }); 420} 421google.maps.event.addDomListener(window, 'load', initialize);
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.