Reloading a page programatically

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Marcia Gulesian

    Reloading a page programatically

    Is there a way of reloading a page programatically - for example,

    <script language="javas cript>
    document.locati on.reload()
    </script>

    BUT NOT HAVING TO MANUALLY CLICK A "RESET" BUTTOM.


  • kaeli

    #2
    Re: Reloading a page programatically

    In article <3FA6B4CA.26892 CD@theworld.com >, mg@theworld.com enlightened
    us with...[color=blue]
    > Is there a way of reloading a page programatically - for example,
    >
    > <script language="javas cript>
    > document.locati on.reload()
    > </script>
    >
    > BUT NOT HAVING TO MANUALLY CLICK A "RESET" BUTTOM.
    >
    >
    >[/color]

    That would do just that.

    It would do it ad nauseum, though. :)

    You could do it as part of a setTimeout if you wanted it reloaded, say,
    every 5 minutes.

    Here's mine. I use it with a frameset and this is the top frame, so it
    has "self" in it.
    <script type="text/javascript" language="javas cript">
    // settimeout for session expiration - check every 5 minutes
    function reloadMe()
    {
    self.document.l ocation.reload( );
    }
    setTimeout("rel oadMe()",1000*6 0*5);
    </script>
    -------------------------------------------------
    ~kaeli~
    Jesus saves, Allah protects, and Cthulhu
    thinks you'd make a nice sandwich.


    -------------------------------------------------

    Comment

    Working...