Request.ServerVariables("HTTP_REFERER")

Discussion in 'ASP General' started by F@yy@Z, Jan 20, 2004.

  1. F@yy@Z

    F@yy@Z Guest

    Hi All

    I am using Request.ServerVariables("HTTP_REFERER") to refer back in some
    pages but on clint side some pages refered back and some show error page not
    found.

    I dont know whats wrong with code.

    retstr = Request.ServerVariables("HTTP_REFERER")
    if instr(1,ucase(retstr),"STEPPAGE") > 0 then
    returl="wm_steppage.asp?step=2"
    else
    returl="wm_mainpage.asp?step=2"
    end if

    Response.Redirect(returl)


    Any one got any idea why its like this


    Kind regards

    Fayayz
     
    F@yy@Z, Jan 20, 2004
    #1
    1. Advertising

  2. F@yy@Z

    Ken Schaefer Guest

    First, work out where you are being redirected to (eg check IIS logs, or
    write some kind of debugging information to a database)>

    Then on wm_steppage.asp or wm_mainpage.asp do you do any further redirects?
    Maybe you're redirecting to a non-existant page?

    Cheers
    Ken

    "F@yy@Z" <> wrote in message
    news:%...
    : Hi All
    :
    : I am using Request.ServerVariables("HTTP_REFERER") to refer back in some
    : pages but on clint side some pages refered back and some show error page
    not
    : found.
    :
    : I dont know whats wrong with code.
    :
    : retstr = Request.ServerVariables("HTTP_REFERER")
    : if instr(1,ucase(retstr),"STEPPAGE") > 0 then
    : returl="wm_steppage.asp?step=2"
    : else
    : returl="wm_mainpage.asp?step=2"
    : end if
    :
    : Response.Redirect(returl)
    :
    :
    : Any one got any idea why its like this
    :
    :
    : Kind regards
    :
    : Fayayz
    :
    :
     
    Ken Schaefer, Jan 20, 2004
    #2
    1. Advertising

  3. F@yy@Z

    aa Guest

    When it throws "not found" it usually indicates the filename and the path
    it is looking for - do these match the name and the path of the file you
    want to redirect to?



    "F@yy@Z" <> wrote in message
    news:#...
    > Hi All
    >
    > I am using Request.ServerVariables("HTTP_REFERER") to refer back in some
    > pages but on clint side some pages refered back and some show error page

    not
    > found.
    >
    > I dont know whats wrong with code.
    >
    > retstr = Request.ServerVariables("HTTP_REFERER")
    > if instr(1,ucase(retstr),"STEPPAGE") > 0 then
    > returl="wm_steppage.asp?step=2"
    > else
    > returl="wm_mainpage.asp?step=2"
    > end if
    >
    > Response.Redirect(returl)
    >
    >
    > Any one got any idea why its like this
    >
    >
    > Kind regards
    >
    > Fayayz
    >
    >
     
    aa, Jan 20, 2004
    #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. Elliot M. Rodriguez
    Replies:
    1
    Views:
    673
    bruce barker
    Feb 12, 2004
  2. =?Utf-8?B?cHBhdGVs?=

    Request.ServerVariables ("HTTP_REFERER") using https

    =?Utf-8?B?cHBhdGVs?=, Mar 2, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    3,616
    Eric Lawrence [MSFT]
    Mar 3, 2004
  3. Jake
    Replies:
    4
    Views:
    12,567
    Craig Deelsnyder
    Apr 20, 2005
  4. Wayne  Wengert

    Request.ServerVariables("HTTP_REFERER")

    Wayne Wengert, Sep 27, 2003, in forum: ASP General
    Replies:
    3
    Views:
    148
    Wayne Wengert
    Sep 27, 2003
  5. JW
    Replies:
    2
    Views:
    442
    Tony B
    Nov 2, 2003
Loading...

Share This Page