reloading a frame on a timer

Discussion in 'HTML' started by Ike, Feb 17, 2004.

  1. Ike

    Ike Guest

    Suppose I have two frames, as shown in the script below. One of the frames,
    I would like to have reload every ten minutes or so. Hower, the frame I wish
    to reload is a php script, which executes and creates a png image which gets
    displayed directly to the browser frame (therefore, the image is NOT written
    to the server itself, and the page that gets displayed in the frame I wish
    to update is a png image mime type).

    How can I amend my script in my page which holds the frameset (i.e. the
    parent) such that only one particular frame is updated at a fixed interval?

    Thanks, Ike

    <frameset rows="10%,90%>
    <frame src="ggtab1a.php" name="main" scrolling="no" noresize
    FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="1"
    marginheight="1">
    <?php
    echo "<frame src=\"reports/homepages/" . $username.".php\" ";
    ?>
    name="work1" FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="0"
     
    Ike, Feb 17, 2004
    #1
    1. Advertising

  2. Ike

    CountScubula Guest

    I think something like this could benifiet you:
    http://gzen.myhq.info/test/time.php

    example source shown here:
    http://www-4.gzentools.com/snippetview.php?c=Concepts&v=time.php


    --
    Mike Bradley
    http://www.gzentools.com -- free online php tools
    "Ike" <> wrote in message
    news:OPrYb.8611$...
    > Suppose I have two frames, as shown in the script below. One of the

    frames,
    > I would like to have reload every ten minutes or so. Hower, the frame I

    wish
    > to reload is a php script, which executes and creates a png image which

    gets
    > displayed directly to the browser frame (therefore, the image is NOT

    written
    > to the server itself, and the page that gets displayed in the frame I wish
    > to update is a png image mime type).
    >
    > How can I amend my script in my page which holds the frameset (i.e. the
    > parent) such that only one particular frame is updated at a fixed

    interval?
    >
    > Thanks, Ike
    >
    > <frameset rows="10%,90%>
    > <frame src="ggtab1a.php" name="main" scrolling="no" noresize
    > FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="1"
    > marginheight="1">
    > <?php
    > echo "<frame src=\"reports/homepages/" . $username.".php\" ";
    > ?>
    > name="work1" FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="0"
    >
    >
    >
     
    CountScubula, Feb 17, 2004
    #2
    1. Advertising

  3. CountScubula wrote:

    > I think something like this could benifiet you:
    > http://gzen.myhq.info/test/time.php
    >
    > example source shown here:
    > http://www-4.gzentools.com/snippetview.php?c=Concepts&v=time.php
    >
    >
    > --
    > Mike Bradley
    > http://www.gzentools.com -- free online php tools
    > "Ike" <> wrote in message
    > news:OPrYb.8611$...
    >> Suppose I have two frames, as shown in the script below. One of the

    > frames,
    >> I would like to have reload every ten minutes or so. Hower, the frame I

    > wish
    >> to reload is a php script, which executes and creates a png image which

    > gets
    >> displayed directly to the browser frame (therefore, the image is NOT

    > written
    >> to the server itself, and the page that gets displayed in the frame I
    >> wish to update is a png image mime type).
    >>
    >> How can I amend my script in my page which holds the frameset (i.e. the
    >> parent) such that only one particular frame is updated at a fixed

    > interval?
    >>
    >> Thanks, Ike
    >>
    >> <frameset rows="10%,90%>
    >> <frame src="ggtab1a.php" name="main" scrolling="no" noresize
    >> FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="1"
    >> marginheight="1">
    >> <?php
    >> echo "<frame src=\"reports/homepages/" . $username.".php\" ";
    >> ?>
    >> name="work1" FRAMEBORDER=0 BORDER=0 FRAMESPACING=0 marginwidth="0"
    >>
    >>
    >>


    Not too hard to pull off. I've got something that does this myself, but it
    reads and displays a log file.

    Use some JavaScript. It works wonderfully.

    (Might not work as is)
    function reloadWindow(frameNameOrIndex)
    {parent.frames[frameNameOrIndex].location.href =
    parent.frames[frameNameOrIndex].location;}

    function reloadKickOff(minutesToReload,frameNameOrIndex)
    {
    secondsToReload = 60 * minutesToReload;
    setTimeOut(reloadWindow(frameNameOrIndex),10);
    }

    Stick that in a javascript block in one of the frames and call the
    reloadKickOff function.
     
    Mike Discenza, Feb 18, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Anita Meyer
    Replies:
    2
    Views:
    3,437
    Anita Meyer
    Jan 28, 2005
  2. K B
    Replies:
    0
    Views:
    472
  3. Gareth
    Replies:
    0
    Views:
    148
    Gareth
    Sep 16, 2004
  4. ROBT NISHIDA

    Problems with reloading a frame

    ROBT NISHIDA, Apr 19, 2005, in forum: Javascript
    Replies:
    1
    Views:
    88
    enrique
    Apr 20, 2005
  5. Dynamo

    Help with reloading frame page please

    Dynamo, Jun 28, 2005, in forum: Javascript
    Replies:
    1
    Views:
    98
    David Dorward
    Jun 28, 2005
Loading...

Share This Page