Help with understanding of window handling??

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

    Help with understanding of window handling??

    Please bear with me as I am not a skilled html programmer. I have a
    situation that I am having difficulty overcoming and perhaps you
    "experts" can show me the way.

    I have a given web site where the first page is a login page. From
    this page an imbedded <FORM> contains a <TARGET="_blank "> to open the
    reference cgi (a perl script) in a new window. The perl script
    authenticates the login and then does one of two things.

    If successful it generates a dynamic page of content output to the 2nd
    window.

    If NOT successful it redisplays the login screen which now contains an
    error message.

    Obviously this works great IF the login is successful. However, if
    not the redisplayed login in displayed in the 2nd window as well. Of
    course this is not correct.

    My question(s) relate to the following:

    How can I cause the redisplayed login page to display in the 1st
    window and then close the 2nd window. OR, is there any way to modify
    the message field in the 1st screen from the 2nd screen then close the
    2nd window?

    Or, is there a better way to do this? And, remember, the generated
    successful page is dynamic so its not as easy as calling an html URL.

    Advice, suggestions, recommendations very much appreciated. We all
    have to learn.

    Thanks

    Bob
  • Dave Patton

    #2
    Re: Help with understanding of window handling??

    R.Mariotti@Fina ncialDataCorp.c om (Bob Mariotti) wrote in
    news:3f29bcc9.1 34463071@news.c shore.com:
    [color=blue]
    > Please bear with me as I am not a skilled html programmer. I have a
    > situation that I am having difficulty overcoming and perhaps you
    > "experts" can show me the way.
    >
    > I have a given web site where the first page is a login page. From
    > this page an imbedded <FORM> contains a <TARGET="_blank "> to open the
    > reference cgi (a perl script) in a new window. The perl script
    > authenticates the login and then does one of two things.
    >
    > If successful it generates a dynamic page of content output to the 2nd
    > window.
    >
    > If NOT successful it redisplays the login screen which now contains an
    > error message.
    >
    > Obviously this works great IF the login is successful. However, if
    > not the redisplayed login in displayed in the 2nd window as well. Of
    > course this is not correct.
    >
    > My question(s) relate to the following:
    >
    > How can I cause the redisplayed login page to display in the 1st
    > window and then close the 2nd window. OR, is there any way to modify
    > the message field in the 1st screen from the 2nd screen then close the
    > 2nd window?
    >
    > Or, is there a better way to do this? And, remember, the generated
    > successful page is dynamic so its not as easy as calling an html URL.
    >
    > Advice, suggestions, recommendations very much appreciated. We all
    > have to learn.[/color]

    Use server-side scripting(e.g. perl, PHP) to generate the login page
    content, and accept/validate the login data, and either generate
    a 'please try again' login page or the page with the dynamic content.
    All this in the same window.
    Your approach won't work if the user agent(e.g. browser) has
    popup windows disabled.

    --
    Dave Patton
    Canadian Coordinator, the Degree Confluence Project
    http://www.confluence.org dpatton at confluence dot org
    My website: http://members.shaw.ca/davepatton/
    Vancouver/Whistler - host of the 2010 Winter Olympics

    Comment

    • Jukka K. Korpela

      #3
      Re: Help with understanding of window handling??

      R.Mariotti@Fina ncialDataCorp.c om (Bob Mariotti) wrote:
      [color=blue]
      > Please bear with me as I am not a skilled html programmer.[/color]

      None of us is, but many of us know HTML well enough to understand that
      is not programming at all.
      [color=blue]
      > I have a given web site where the first page is a login page. From
      > this page an imbedded <FORM> contains a <TARGET="_blank "> to open
      > the reference cgi (a perl script) in a new window.[/color]

      Why? It would be simpler to anyone to use the existing window.
      [color=blue]
      > Obviously this works great IF the login is successful.[/color]

      What's so great in having a login screen on the window after you've
      logged in?
      [color=blue]
      > How can I cause the redisplayed login page to display in the 1st
      > window and then close the 2nd window.[/color]

      You cannot do that in HTML. If you really want to try something like
      that, it would be programming, hence not HTML, thus off-topic here.

      --
      Yucca, http://www.cs.tut.fi/~jkorpela/
      Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

      Comment

      • Bob Mariotti

        #4
        Re: Help with understanding of window handling??

        OK - I most certainly understand what you are all saying about keeping
        all the action in the current window.

        However, my issue is relative to the history (i.e.: Back Button).

        When the user is done with the site and returns to the login page
        (i.e.: logs off) the history needs to GO AWAY to prevent unauthorized
        use of the back button URL's.

        Any suggestions as to how better to handle this?

        Thanks

        Bob

        Comment

        Working...