?
Solved

auto switch between different webpages?

Posted on 2009-05-01
7
Medium Priority
?
1,819 Views
Last Modified: 2013-11-10
HI - I'm about to make a newsboard for our school. I will have to show some of my own webpages - no problem - I ll guees I can use the meta tag "Page-Exit"  and "Refresh" to switch between these pages. Though this might not be the best solution ..?
BUT I also have to show a page or two from another webserver - and offcause here I can't
use this method. How do I do this.
I'm using ASP (classic) and VB Script.
Hope someone out there can give me a hint / tip
Thanks Otto
0
Comment
Question by:otto_leholt
  • 4
  • 3
7 Comments
 
LVL 1

Assisted Solution

by:wpgwiggum
wpgwiggum earned 2000 total points
ID: 24288257
You might want to use an iFrame, and have a javascript timer loop through a list of sites...setting the location of the iFrame to the site. This would probably be the most dynamic..and give you the most control. You can set the iFrame to be the size of the window, so that the user thinks they are at the external site.
0
 

Author Comment

by:otto_leholt
ID: 24289136
Thanks for the response. Well I search for " javascript timer loop" but did'nt find something that I can use. I'm not an expert - or even very familiar with javascripts. So I need a script that can open a new window an show my external website ( http://www.lectio.dk/lectio/351/RapportDay.aspx ) and then close this window again after something like 30 sek , and then show my own pages again. There should be no user interaction.
The script is for a 50" monitor / news board in the hallway in my school.
best regards Otto Leholt
0
 
LVL 1

Assisted Solution

by:wpgwiggum
wpgwiggum earned 2000 total points
ID: 24290174
With digital signage, it is my experience that you don't really want to have a new window pop up...it doesn't look very nice. You will just want the display to appear to change the page it is displaying.

If you still want it to pop up in a new window, you will have to keep a handle on the new window...so that you can close it later (if the browser will allow)

I did a quick search in google for 'javascript iframe' and came up with this page: http://www.devarticles.com/c/a/JavaScript/Working-with-IFRAME-in-JavaScript/. It may prove useful.

I've included a bit of framework for what you might want to do. It will have to be in the page containing the iFrame.
<script type="text/javascript">
<!--
function setIFrameToOtherPage(){
    //set the location of iframe to a value of your array of valid pages
    //have your page call the setIFrameToMyPage() after 30 seconds
    setTimeout('setIFrameToMyPage()',30000);
}
function setIFrameToMyPage(){
    //set the location of iframe to your content
    //have your page call the setIFrameToOtherPage() after 50 seconds
    setTimeout('setIFrameToOtherPage()',50000);
}
 
//start the loop
setIFrameToMyPage();
//-->
</script>

Open in new window

0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:otto_leholt
ID: 24290880
Thanks wpgwiggum:
Now I got was Iframe is about - but I need to find out how to combine your script with my Iframe ..
I better have a look in my old javaScript books... as I said I'm not very familiar with java.
thanks otto
sorry I'm really a bit ashamed about this - because one here recive a lot off help for .. nothing .
0
 
LVL 1

Assisted Solution

by:wpgwiggum
wpgwiggum earned 2000 total points
ID: 24291426
If you are familar with VBScript, you may want to see if you can accomplish the same tasks with a language you know. I'm not very familar with VBScript myself...but usually you can get the same thing done just in slightly different ways.

Once the iframe is setup, you really just need a single line of code setting the 'src' attribute of your iframe in each of the functions I made up above.
0
 

Accepted Solution

by:
otto_leholt earned 0 total points
ID: 24362233
Hi
I havent found the perfect solution - but have used the code showed below.
The result can be seen at http://www.frberg-hf.dk/info/aula/ 
Any suggestions are still very very welcome.
Thanks for the help so far.
best wishes Otto Leholt
<meta http-equiv="refresh" content="40">
<script type="text/javascript">
var WindowObjectReference=null;
 
function openSites() {
var openOneAtATime=new Array()
//openOneAtATime[0]="http://www.frberg-hf.dk/info/aula/news_aula.asp"
openOneAtATime[0]="http://www.lectio.dk/lectio/351/RapportDay.aspx"
openOneAtATime[1]="http://www.frberg-hf.dk/info/"
openOneAtATime[2]="photo.html"
 
var i=0;
for (i=0;i<openOneAtATime.length;i++) {
     setTimeout("WindowObjectReference = window.open('"+openOneAtATime[i]+"','window1')",10000*i);
    //setTimeout("WindowObjectReference.close()",10000*(i+0.8))
    }
}
openSites()
</script>

Open in new window

0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Measuring Server's processing rate with a simple powershell command. The differences in processing rate also was recorded in different use-cases, when a server in free and busy states.
This video teaches users how to migrate an existing Wordpress website to a new domain.
The viewer will learn how to count occurrences of each item in an array.
Suggested Courses
Course of the Month17 days, 1 hour left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question