how to redirect to a frames-based html page and load the right html when coming from an ASP.NET page

Discussion in 'ASP .Net' started by Mark Kamoski, Aug 13, 2003.

  1. Mark Kamoski

    Mark Kamoski Guest

    Hi--

    I need a code sample of how to redirect from an ASP.NET page to a
    frames-based html page and specifying what should load in the destination's
    frames.

    Any ideas?

    (Even air-code is much appreciated.)

    The long story is this. I have 2 sites. One is in DotNet and one is html
    and frames. The DotNet site is a section by section rewrite of the html and
    frames site. So the html site has 2 frames, one is the left nav and the
    other is content. So, from the html site, I can simply point to a new
    section that is in DotNet and the user goes to the DotNet site for that
    section. Then, when in the DotNet site, if the user wants to go to a
    section has NOT yet been rewritten in DotNet, then the DotNet nav needs to
    send the user back to the html site and load the left nav and the correct
    content. And so on.

    If you can help, please post a code snippet.

    Thank you very much.

    --Mark
     
    Mark Kamoski, Aug 13, 2003
    #1
    1. Advertising

  2. Mark Kamoski

    Ram Guest

    Write the follwoing code in your code behind page. Change the outputstr as you need.

    Dim outputstr As String
    outputstr = "<html>" _
    & vbCrLf & "<head>" _
    & vbCrLf & "<title>Forms from code behind</title>" _
    & vbCrLf & "</head>" _
    & vbCrLf & "<frameset rows='108,*,22'>" _
    & vbCrLf & "<frame name='Title' src='http://www.hotmail.com'>" _
    & vbCrLf & "<frame name='body' src='http://www.hotmail.com'>" _
    & vbCrLf & "<frame name='footer'src='http://www.hotmail.com'>" _
    & vbCrLf & "</frameset>" _
    & vbCrLf & "</html>"
    Response.Write(outputstr)

    In your ASPX page remove all the html content, and retain only the page directive.

    Hope this helps you.

    Ram

    "Mark Kamoski" <> wrote in message news:<#>...
    > Hi--
    >
    > I need a code sample of how to redirect from an ASP.NET page to a
    > frames-based html page and specifying what should load in the destination's
    > frames.
    >
    > Any ideas?
    >
    > (Even air-code is much appreciated.)
    >
    > The long story is this. I have 2 sites. One is in DotNet and one is html
    > and frames. The DotNet site is a section by section rewrite of the html and
    > frames site. So the html site has 2 frames, one is the left nav and the
    > other is content. So, from the html site, I can simply point to a new
    > section that is in DotNet and the user goes to the DotNet site for that
    > section. Then, when in the DotNet site, if the user wants to go to a
    > section has NOT yet been rewritten in DotNet, then the DotNet nav needs to
    > send the user back to the html site and load the left nav and the correct
    > content. And so on.
    >
    > If you can help, please post a code snippet.
    >
    > Thank you very much.
    >
    > --Mark
     
    Ram, Aug 13, 2003
    #2
    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. Drebin
    Replies:
    15
    Views:
    13,885
    slyi .
    Nov 23, 2004
  2. Vikram

    client id not coming right

    Vikram, Dec 27, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    350
    Vikram
    Dec 27, 2005
  3. Olikara Vipin
    Replies:
    1
    Views:
    513
    Debian User
    Jan 16, 2004
  4. Philip
    Replies:
    3
    Views:
    975
    Karl Groves
    Jun 28, 2004
  5. Steve Holden

    PyCon is Coming! PyCon is Coming!

    Steve Holden, Jan 5, 2006, in forum: Python
    Replies:
    0
    Views:
    315
    Steve Holden
    Jan 5, 2006
Loading...

Share This Page