• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

[MMM-iFrameReload]: iFrame won't refresh

Scheduled Pinned Locked Moved Solved Troubleshooting
3 Posts 2 Posters 3.5k Views 2 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    binderth
    last edited by binderth May 26, 2017, 3:21 PM May 26, 2017, 3:15 PM

    After I managed to load the iFrame at all (see https://forum.magicmirror.builders/topic/2637/mmm-iframereload-iframe-won-t-load), the iFrame (in my case the present snapshot picture of a webcam) is loaded, but not refreshed.
    I made a pull request to update the readme of https://github.com/TheBogueRat/MMM-iFrameReload, see https://github.com/TheBogueRat/MMM-iFrameReload/pull/5 , so my config.js looks like this:

    		{
    		module: 'MMM-iFrameReload',
    		position: 'top_left',	// This can be any of the regions.
    		config: {
    			// See 'Configuration options' for more information.
    				url: 'http://192.168.178.xx:xx/cgi-bin/CGIProxy.fcgi?cmd=snapPicture&usr=USER&pwd=PASS',
    				width: '640px', // Optional. Default: 100%
    				height: '360px', //Optional. Default: 100px
    				refreshInterval: 10  //Optional. Default: 3600 = 1 hour
    			}
    		},
    

    with this, the iframe is loaded, but not refreshed after 10 seconds, I do get the following every 10 seconds in the console - so I guess principially it works?:

    attempting to update dom for iFrameReload  MMM-iFrameReload.js:52:3
    /"this/" module is: [object Object]  MMM-iFrameReload.js:53:3
    attempting to update dom for iFrameReload  MMM-iFrameReload.js:52:3
    /"this/" module is: [object Object]  MMM-iFrameReload.js:53:3
    

    what I did also is changing the last Attribute:

    				refreshInterval: '10'  //Optional. Default: 3600 = 1 hour
    

    removed and added the ’ around the 10 and added a comma at the end of the line. still the same: iframe gets loaded, but not refreshed.

    B 1 Reply Last reply May 26, 2017, 4:10 PM Reply Quote 0
    • B Offline
      binderth @binderth
      last edited by May 26, 2017, 4:10 PM

      @binderth
      I want to solve! ;)
      see on github: https://github.com/TheBogueRat/MMM-iFrameReload/issues/2

      I also changed the “MMM-iFrameReload.js”: line 32:

      		iframe.src =  this.config.url + '&' + new Date().getTime();
      

      this way, the URL is different everytime - perhaps it is some kind of caching issue.?

      D 1 Reply Last reply Jul 15, 2018, 10:21 PM Reply Quote 1
      • D Offline
        daikaiju @binderth
        last edited by Jul 15, 2018, 10:21 PM

        @binderth Can confirm this works!

        1 Reply Last reply Reply Quote 0
        • 1 / 1
        • First post
          Last post
        Enjoying MagicMirror? Please consider a donation!
        MagicMirror created by Michael Teeuw.
        Forum managed by Sam, technical setup by Karsten.
        This forum is using NodeBB as its core | Contributors
        Contact | Privacy Policy