March 29, 2017, 04:08:41 AM
Welcome, Guest. Please login or register.
Did you miss your activation email
News: Stay up to date with everything that's happening at http://plus.digitalsignage.com

MediaSignage support forum



Author Topic: Iframe auto scroll loop!  (Read 288 times)

HVL

  • Jr. Member
  • **
  • Posts: 80
  • Karma: +2/-0
    • View Profile
Iframe auto scroll loop!
« on: February 07, 2017, 12:26:09 AM »
Hello All

So I am trying to get and Iframe of google calendar to auto scroll for for a set amount of time. Before it refreshes and starts over.

http://hvl-gruppen.dk/mediasignage/herfoelge/gcal.html    is what im trying to scroll but cant seem to get it to work.


http://www.dynamicdrive.com/forums/showthread.php?40339-IFRAME-Autoscroll

http://www.dynamicdrive.com/dynamicindex2/external.htm



Code: [Select]
/***********************************************
* IFRAME Scroller script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

//specify path to your external page:
var iframesrc="external.htm"

document.write('<iframe id="datamain" src= "'+iframesrc+'" width="1200px" height="400px"

marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="1"

scrolling="no"></iframe>')

Code: [Select]
var scrollspeed=cache=2

var initialdelay=500

function initializeScroller(){
dataobj=document.all? document.all.datacontainer : document.getElementById("datacontainer")
dataobj.style.top="5px"
setTimeout("getdataheight()", initialdelay)
}

function getdataheight(){
thelength=dataobj.offsetHeight
if (thelength==0)
setTimeout("getdataheight()",10)
else
scrollDiv()
}
function scrollDiv(){
dataobj.style.top=parseInt(dataobj.style.top)-scrollspeed+"px"
if (parseInt(dataobj.style.top)<thelength*(-1))
dataobj.style.top="5px"
setTimeout("scrollDiv()",40)
}

if (window.addEventListener)
window.addEventListener("load", initialiazeScroller, false)
else if (window.attachEvent)
window.attachEvent("onload, initializerScroller)
else
window.onload=initializeScroller



Have been reading thru these. And feel there is an answer somewhere in there. But cant get it to work.

Anyone inhere that understand it better than I do, and can give me an idea of how to set it up so it works ?

regards Hvl

Gert

  • Jr. Member
  • **
  • Posts: 67
  • Karma: +0/-0
    • View Profile
Re: Iframe auto scroll loop!
« Reply #1 on: February 10, 2017, 06:14:28 AM »
Hello HVL, please send your question to team info@watchcomm.nl and they will come back to you

HVL

  • Jr. Member
  • **
  • Posts: 80
  • Karma: +2/-0
    • View Profile
Re: Iframe auto scroll loop!
« Reply #2 on: February 27, 2017, 11:18:29 PM »
Did as you asked.

Been 10 days. no reply yet :)

/hvl

HVL

  • Jr. Member
  • **
  • Posts: 80
  • Karma: +2/-0
    • View Profile
Re: Iframe auto scroll loop!
« Reply #3 on: March 20, 2017, 06:11:41 AM »
got reply and solution.

they want cash for the solution tho ^^

 

Carbonate design by Bloc
variant: carbon
SMF 2.0.12 | SMF © 2016, Simple Machines