Results 1 to 2 of 2

Thread: Question about image push applets

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Oct 2000
    Posts
    1,463

    Question about image push applets

    I am playing around with some javascript for the push / pull image used on webcam sites. When i run one, it never refreshes the image in my browser when I change the image. It only does if I delete the image and then repost it. It seems my browser looks for the cache or something first. How can I make ANY browser force to load the image without deleting it first?

    Here is the script I am using:


    <SCRIPT>
    <!-- ===================
    browserType = navigator.appName;
    newImage = new Image();
    Srvr_IP= "http://127.0.0.1/myFile.jpg?";
    var dly;
    if (browserType == "Netscape") document.write('<IMG SRC="'+ Srvr_IP +'"

    >')
    else document.write('<IMG SRC="' + Srvr_IP +'" name=ZahidiTV2Web

    Alt="Web Server is off. Please try later." border=1 >');
    uniq= 1;
    newImage.src= Srvr_IP + uniq;
    SnapShot_Loop(4000);
    function SnapShot_Loop(delay)


    {
    dly= delay
    if( document.all) loadNewImage();
    setTimeout("SnapShot_Loop(dly)",delay);
    }
    function loadNewImage()


    {
    Stamp = new Date();
    uniq= Stamp.getTime();
    document.images.ZahidiTV2Web.src= newImage.src;
    newImage.src= Srvr_IP + uniq;
    window.status = "Displaying live video ...";
    }
    </SCRIPT>


    <P>
    Hello

  2. #2
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    This is the Java forum. There's a seperate forum for JavaScript.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width