Solved

Looping HTML Code

Posted on 2002-07-06
5
141 Views
Last Modified: 2010-04-09
I am very new to HTML, but would like to know if there is a way to write a loop into the code as one would do in visual basic.  I have a picture file which is being updated periodicaly and would like to refresh that picture without the need to restart the browser each time.
0
Comment
Question by:BOBH
  • 2
  • 2
5 Comments
 
LVL 44

Accepted Solution

by:
bruintje earned 50 total points
Comment Utility
Hi BOBH,

you can use the refresh tag, in html there's no such thing as looping for that you could use script but i guess that isn't nessecary for what you're trying to do here

http://www.awakemm.com/christopher/knowledge/metatags/refresh.html

HAGD:O)Bruintje
0
 
LVL 33

Expert Comment

by:knightEknight
Comment Utility
or, you could do reload the image without reloading the whole page:

<BODY onLoad='setInterval("document.images[\"yourImageName\"].src=\"images/yourimage.gif?rnd=\"+Math.random()",10000);'>


<IMG name="yourImageName" src="images/yourimage.gif" border="0">

the 10000 in the setInterval is the number of milliseconds to wait for each refresh (10 seconds in this case).
0
 
LVL 44

Expert Comment

by:bruintje
Comment Utility
learning all the time ;)
0
 

Author Comment

by:BOBH
Comment Utility
Thanks to both of you.  I'll play with these suggestions and be back
                                      BobH
0
 

Author Comment

by:BOBH
Comment Utility
I have the following code which generates a very nice selection box but now how do I steer the selection to where it is supposed to go when the camera is selected. In this case a different Java Applet for each camera.

<Center>
<Select Name="field name" SIZE=1>                 change SIZE to 4 for selection box
<OPTION>Camera 1</OPTION>
<OPTION>Camera 2</OPTION>
<OPTION>Camera 3</OPTION>
<OPTION>Camera 4</OPTION>

0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

763 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

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now