Redirection question...

Discussion in 'ASP General' started by Frank Side Burns, Mar 23, 2005.

  1. I have a web page (let's call it main.aspx) that must only be accessible
    thru another web page in my web application. Users should not be able to
    browse directly to 'main.aspx'...they can only be redirected their from
    another page on my site. How does one go about doing this?

    Thanks for any help.
    Frank Side Burns, Mar 23, 2005
    #1
    1. Advertising

  2. Frank Side Burns

    Steven Burn Guest

    Not fool proof but;

    Opt 1;

    <%
    If Session(Request.ServerVariables("REMOTE_ADDR")) <> True Then
    Response.Redirect "theotherpage_URL"
    End If
    %>

    Opt 2;

    <%
    If Request.ServerVariables("HTTP_REFERER") <> "theotherpage_URL" then
    Response.Redirect "theotherpage_URL"
    End If
    %>

    Opt 3: Use cookies (again not fool proof but..... might work)

    --
    Regards

    Steven Burn
    Ur I.T. Mate Group
    www.it-mate.co.uk

    Keeping it FREE!

    "Frank Side Burns" <> wrote in message news:sdj0e.766007$8l.384854@pd7tw1no...
    > I have a web page (let's call it main.aspx) that must only be accessible
    > thru another web page in my web application. Users should not be able to
    > browse directly to 'main.aspx'...they can only be redirected their from
    > another page on my site. How does one go about doing this?
    >
    > Thanks for any help.
    >
    >
    >
    >
    >
    Steven Burn, Mar 23, 2005
    #2
    1. Advertising

  3. Thanks for the ideas. I went with the 'hidden variable' technique...works
    fine.



    "Frank Side Burns" <> wrote in message
    news:sdj0e.766007$8l.384854@pd7tw1no...
    > I have a web page (let's call it main.aspx) that must only be accessible
    > thru another web page in my web application. Users should not be able to
    > browse directly to 'main.aspx'...they can only be redirected their from
    > another page on my site. How does one go about doing this?
    >
    > Thanks for any help.
    >
    >
    >
    >
    >
    Frank Side Burns, Mar 23, 2005
    #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. David Kleyman

    Authentication/Automatic redirection question

    David Kleyman, Dec 17, 2003, in forum: ASP .Net
    Replies:
    3
    Views:
    650
    David Kleyman
    Dec 17, 2003
  2. Dot net work

    Tough redirection question

    Dot net work, Apr 11, 2004, in forum: ASP .Net
    Replies:
    4
    Views:
    460
    Dot net work
    Apr 12, 2004
  3. Code Monkee

    Redirection question

    Code Monkee, Dec 16, 2003, in forum: HTML
    Replies:
    6
    Views:
    362
    Leif K-Brooks
    Dec 17, 2003
  4. Disco Octopus

    Redirection Question

    Disco Octopus, Apr 28, 2005, in forum: HTML
    Replies:
    2
    Views:
    400
    Edwin van der Vaart
    Apr 28, 2005
  5. Jp Calderone

    Re: ouput redirection..a newbie question

    Jp Calderone, Dec 15, 2003, in forum: Python
    Replies:
    2
    Views:
    298
    Lonnie Princehouse
    Dec 15, 2003
Loading...

Share This Page