try binding to this
authorSteve Sutton <steve@gaslightmedia.com>
Mon, 1 Feb 2016 21:11:30 +0000 (16:11 -0500)
committerSteve Sutton <steve@gaslightmedia.com>
Mon, 1 Feb 2016 21:11:30 +0000 (16:11 -0500)
js/app.js
js/custom/pageSetup.js

index 19d6e31..00469a9 100644 (file)
--- a/js/app.js
+++ b/js/app.js
@@ -105,7 +105,7 @@ $(document).ready(function () {
         $('#cam3').attr('src','http://www.otsegocountymi.gov/images/OtsegoCoAirCam.jpg?b=' + Math.random());
         $('#cam4').attr('src','http://www.otsegocountymi.gov/images/OtsegoCoAnimalCam.jpg?b=' + Math.random());
         $('#cam5').attr('src','http://www.weather.gov/images/apx/webcam/webcam.jpg?b=' + Math.random());
-        setTimeout("glmReloadImg()", 10000);
+        setTimeout(this.glmReloadImg().bind(this), 10000);
     }
     glmReloadImg();
 
index 3004c8e..a0bd020 100644 (file)
@@ -96,7 +96,7 @@ $(document).ready(function () {
         $('#cam3').attr('src','http://www.otsegocountymi.gov/images/OtsegoCoAirCam.jpg?b=' + Math.random());
         $('#cam4').attr('src','http://www.otsegocountymi.gov/images/OtsegoCoAnimalCam.jpg?b=' + Math.random());
         $('#cam5').attr('src','http://www.weather.gov/images/apx/webcam/webcam.jpg?b=' + Math.random());
-        setTimeout("glmReloadImg()", 10000);
+        setTimeout(this.glmReloadImg().bind(this), 10000);
     }
     glmReloadImg();