473,386 Members | 1,883 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

refresh some pages every 2 seconds

Hi guys,
I want to refresh some pages every 2 seconds.
however, these html pages are not in my site, they could be any pages from
yahoo.com or msn.com.
I can create a page, which redirect to public internet html page, but how
can I do this in a loop?
do I need to write a console application to make it work?
thanks
k


Nov 19 '05 #1
3 2078
Kevin,

Two ways I can think of:

1) Use a frame / iframe to call the other page. Then use client side code to
refresh the frame.
2) Get a copy of the page via an html request object, place the entire page
into a literal control within your own page. (This method may cause
unexpected results depending on the code contained in the other pages. For
example if they include a form tag or two it could mess things up a great
deal. You may need to parse the string returned to eliminate things like
that.

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
"Kevin" <pe******@hotmail.com> wrote in message
news:OH****************@tk2msftngp13.phx.gbl...
Hi guys,
I want to refresh some pages every 2 seconds.
however, these html pages are not in my site, they could be any pages from
yahoo.com or msn.com.
I can create a page, which redirect to public internet html page, but how
can I do this in a loop?
do I need to write a console application to make it work?
thanks
k

Nov 19 '05 #2
I don't think frame/iframe is possible.

for example:
having navigation.html and main.html in the frame.
I don't think a frame can contain aspx page. therefore just plain html is
not possible.
<META HTTP-EQUIV="Refresh"
CONTENT="5;URL=http://www./your_host.com/your_site/your_page.html">

so this refresh can only refresh page on nav.html. The point is I want
refresh happen on main.html every 2 seconds.
I understand client code needs to be on nav.html. but still, it's not
possible
"S. Justin Gengo" <justin@[no_spam_please]aboutfortunate.com> wrote in
message news:OV*************@TK2MSFTNGP10.phx.gbl...
Kevin,

Two ways I can think of:

1) Use a frame / iframe to call the other page. Then use client side code
to refresh the frame.
2) Get a copy of the page via an html request object, place the entire
page into a literal control within your own page. (This method may cause
unexpected results depending on the code contained in the other pages. For
example if they include a form tag or two it could mess things up a great
deal. You may need to parse the string returned to eliminate things like
that.

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
"Kevin" <pe******@hotmail.com> wrote in message
news:OH****************@tk2msftngp13.phx.gbl...
Hi guys,
I want to refresh some pages every 2 seconds.
however, these html pages are not in my site, they could be any pages
from yahoo.com or msn.com.
I can create a page, which redirect to public internet html page, but how
can I do this in a loop?
do I need to write a console application to make it work?
thanks
k


Nov 19 '05 #3
Kevin,

Here's the way it would work:

You split your page into two frames any size. Let's say the top frame is
very small. Then load a page into the top frame, let's call it refresh.html.

The refresh.html page will contain a javascript with a timer that refreshes
the bottom frame, something like

window.parent.mainFrame.location.reload();

Now, load your .aspx page into the bottom frame.

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
"Kevin" <pe******@hotmail.com> wrote in message
news:eu*************@TK2MSFTNGP15.phx.gbl...
I don't think frame/iframe is possible.

for example:
having navigation.html and main.html in the frame.
I don't think a frame can contain aspx page. therefore just plain html is
not possible.
<META HTTP-EQUIV="Refresh"
CONTENT="5;URL=http://www./your_host.com/your_site/your_page.html">

so this refresh can only refresh page on nav.html. The point is I want
refresh happen on main.html every 2 seconds.
I understand client code needs to be on nav.html. but still, it's not
possible
"S. Justin Gengo" <justin@[no_spam_please]aboutfortunate.com> wrote in
message news:OV*************@TK2MSFTNGP10.phx.gbl...
Kevin,

Two ways I can think of:

1) Use a frame / iframe to call the other page. Then use client side code
to refresh the frame.
2) Get a copy of the page via an html request object, place the entire
page into a literal control within your own page. (This method may cause
unexpected results depending on the code contained in the other pages.
For example if they include a form tag or two it could mess things up a
great deal. You may need to parse the string returned to eliminate things
like that.

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
"Kevin" <pe******@hotmail.com> wrote in message
news:OH****************@tk2msftngp13.phx.gbl...
Hi guys,
I want to refresh some pages every 2 seconds.
however, these html pages are not in my site, they could be any pages
from yahoo.com or msn.com.
I can create a page, which redirect to public internet html page, but
how can I do this in a loop?
do I need to write a console application to make it work?
thanks
k



Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Bilal | last post by:
Hi I have an application with numerous pages. A couple of these pages include a functionality that allows it to be refreshed every 15 secs. My problem is that this "refreshing" works too well: THe...
2
by: Lam | last post by:
Hi I try to write a C# windows program which will read some data from database and display on the screen. It has to refresh the output every 10 seconds because the database keep growing every...
0
by: Brad White | last post by:
Overview: I have a custom web app that has an 'Inbox' that refreshes every 30 seconds. One user uses Outlook to host the web page. Using IE, the refresh works fine. If the user is working in...
8
by: Jason S | last post by:
Hi, is there any way of getting my VB (6.0) program to automatically 'Refresh' an IE window that might be active (window status not applicable). It needs to be able to determine which active IE...
12
by: martin1 | last post by:
All, is there window form refresh property? I try to set up window form refresh per minute. Thanks
10
by: phforum | last post by:
Hi, I wrote a PHP page for user input the information to search the database. And the database data will update every second. I want to set the auto refresh to get the data from database every...
3
by: marik | last post by:
Hi, people. I have a question: Can somebody link me to a simple javascript piece of code, that allows me to get input from a combo box and set the refresh interval of the page to be that...
10
by: Piotr Nowak | last post by:
Hi, Say i have a server process which listens for some changes in database. When a change occurs i want to refresh my page in browser by notyfinig it. I do not want to refresh my page i.e....
16
by: Hemavathi | last post by:
can someone help me with code to refresh my PHP pages every ten seconds?
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.