Automatically open HTML file.

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

    Automatically open HTML file.

    Hello,

    I have very simple question. How I can open with javasript placed in
    one html file anothe html file? Can you recomend some good manual
    where I could read about this?

    Thank you.
  • Andrew Thompson

    #2
    Re: Automatically open HTML file.

    On 28 Nov 2004 03:28:33 -0800, Q wrote:
    [color=blue]
    > I have very simple question. How I can open with javasript placed in
    > one html file anothe html file?[/color]

    Why JS in particular? There is an HTML equivalent that will
    work on UA's with JS disabled.

    <head>
    ....
    <meta http-equiv="refresh" content="3;URL= ./other.htm">
    </head>
    ....

    HTH

    --
    Andrew Thompson
    http://www.PhySci.org/codes/ Web & IT Help
    http://www.PhySci.org/ Open-source software suite
    http://www.1point1C.org/ Science & Technology
    http://www.LensEscapes.com/ Images that escape the mundane

    Comment

    • Razzbar

      #3
      Re: Automatically open HTML file.

      opt_inf_env@yah oo.com (Q) wrote in message news:<5f275cd6. 0411280328.df84 97@posting.goog le.com>...[color=blue]
      > Hello,
      >
      > I have very simple question. How I can open with javasript placed in
      > one html file anothe html file? Can you recomend some good manual
      > where I could read about this?[/color]

      That's how frames work. Frames are individual files called from
      one file/page.

      Also, when you open a window, you open another file/page.

      Comment

      • RobG

        #4
        Re: Automatically open HTML file.

        Andrew Thompson wrote:
        [...][color=blue]
        > <meta http-equiv="refresh" content="3;URL= ./other.htm">[/color]

        Wrong forum, blah blah but since you brought it up...

        Is there any way of disabling "refresh"?

        news.com.au and zdnet.com.au both use it - it's one of *the* most
        annoying things to be half way through reading an article and the
        rotten thing reloads. Plus, if you have 3 or 4 tabs open, they keep
        re-loading, killing download speeds for other stuff.

        I can only presume it increases the hit-count their site, possibly
        increasing their ad revenue or stats.

        --
        Rob

        Comment

        • Andrew Thompson

          #5
          Re: Automatically open HTML file.

          On Mon, 29 Nov 2004 20:35:12 +1000, RobG wrote:
          [color=blue]
          > Andrew Thompson wrote:
          > [...][color=green]
          >> <meta http-equiv="refresh" content="3;URL= ./other.htm">[/color]
          >
          > Wrong forum, blah blah but since you brought it up...[/color]

          Wrong details, depends on browser[1].
          [color=blue]
          > Is there any way of disabling "refresh"?[/color]

          I'll take a wild stab.. [1] IE?

          Internet Options | Security | Custom Level (for the appropriate zone)
          Miscellaneous | Allow META-REFRESH | Disable
          [color=blue]
          > news.com.au and zdnet.com.au both use it ..[/color]

          ( Bastards! ;-)

          --
          Andrew Thompson
          http://www.PhySci.org/codes/ Web & IT Help
          http://www.PhySci.org/ Open-source software suite
          http://www.1point1C.org/ Science & Technology
          http://www.LensEscapes.com/ Images that escape the mundane

          Comment

          • RobG

            #6
            Re: Automatically open HTML file.

            Andrew Thompson wrote:
            [...][color=blue]
            >
            > I'll take a wild stab.. [1] IE?[/color]

            Nope - at work, Firefox on XP, at home Safari on Mac but ya gotta go
            with the odds, eh?

            Work demands IE but I'm a subversive and use Firefox anyway.
            [color=blue]
            > Internet Options | Security | Custom Level (for the appropriate zone)
            > Miscellaneous | Allow META-REFRESH | Disable[/color]

            Sys admin nazis have locked down the corporate desktop so I can't
            access any of the security stuff in IE so I can't disable it. I could
            turn it off in Firefox if I could find it... if it had it...

            --
            Rob

            Comment

            • Q

              #7
              Re: Automatically open HTML file.

              > <head>[color=blue]
              > ...
              > <meta http-equiv="refresh" content="3;URL= ./other.htm">
              > </head>[/color]

              Ok, I think I need concretize my problem. The first file consists a
              text field, which can be filled by user. After pressing "Send" button
              this file (with the usage of PHP) generates a new HTML file, which has
              to be opened automatically. So, unfortunately I cannot use <meta ...>
              because in this case browser opens the second file immediately (no
              matter whether user finished to print text in text field).

              Comment

              • Andrew Thompson

                #8
                Re: Automatically open HTML file.

                On 30 Nov 2004 12:28:53 -0800, Q wrote:
                [color=blue]
                > Ok, I think I need concretize my problem. The first file consists a
                > text field, which can be filled by user. After pressing "Send" button
                > this file (with the usage of PHP) generates a new HTML file, which has
                > to be opened automatically.[/color]

                Specify the 'new.html' as the target of the form element action attribute.

                (Again, no JS required.)

                --
                Andrew Thompson
                http://www.PhySci.org/codes/ Web & IT Help
                http://www.PhySci.org/ Open-source software suite
                http://www.1point1C.org/ Science & Technology
                http://www.LensEscapes.com/ Images that escape the mundane

                Comment

                Working...