Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

WebCam setup

Posted on 2000-05-13
4
Medium Priority
?
138 Views
Last Modified: 2010-04-09
I have an application that sends a new .jpg file to my server every 15 seconds (from my camera).  I tried to use:
<meta HTTP-EQUIV="Refresh" CONTENT="15; URL=http://www.zzz.com/webcam.htm">

to make the page refresh every 15 seconds but it doesn't update the picture.  The html is simply a page with a jpg picture.  How can I make the page continue to update when I send a new picture?
0
Comment
Question by:Lee5
  • 2
4 Comments
 
LVL 22

Expert Comment

by:CJ_S
ID: 2807968
Bu using an image with an additoon ? + randomnumber

ie. with javascript it'd look like:

<script language=javascript>
<!--
var MyImg = new Image();
    function UpdatePic()
    {
       MyImg.src="http://www.mysite.com/image?"+ Math.random();
       document.MyWebcam.src = MyImg.src;    
       setTimeout("UpdatePic()", 150);
    }

setTimeout("UpdatePic()", 150);
//-->
</script>

<img id=MyWebcam>

or something like that. This way you don't even have to use the META refresh tag.
0
 
LVL 22

Expert Comment

by:CJ_S
ID: 2807971
oops.......i meant to

http://www.mysite.com/image.gif? + Math.random();
0
 

Accepted Solution

by:
semkin earned 200 total points
ID: 2810961
Hi!
We have similar page with web-camera.
Also we use a refresh-method for clients with low speed of connection to the Internet.

Try to make so:

=======================================

<META HTTP-EQUIV="EXPIRES" CONTENT="0">
<meta http-equiv="Refresh" content="15">
<meta http-equiv="Pragma" content="no-cache">
</head>

<body>
<img src="http://www.zzz.com/webcam.jpg" width=* height =* >...

=======================================

Differently go to http://weather.tomsk.net, click on an icon with the camera and look a refresh-method.

Good luck!
Excuse for my bad English.
semkin :)
0
 

Author Comment

by:Lee5
ID: 2813904
Thanks
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…

926 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