Results 1 to 3 of 3

Thread: redirecting using a querystring

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jul 2000
    Location
    Belfast
    Posts
    28
    Say I am using a querystring to redirect from a stats page. eg.

    http://www.whatever.com/redirect.asp...sp?a=one&b=two

    Part of the redirect url is lost (b=two) ie. any querystring of the redirect url that follows an "&".

    Can some one tell me how to prevent this happening. Any help would be a great help.

    Charlie

  2. #2
    Hyperactive Member
    Join Date
    Mar 2000
    Location
    Canada
    Posts
    264
    try something like:

    <a href="http://whatever.com/index.asp?<%=server.urlencode ("url=http://www.whatever.com/page.asp?a=one&b=two
    ")%>">

    Not sure if it would help ... but worth a try :-)
    In the beginning the universe was created. This has made a lot of people very angry and is generally regarded as a bad idea.

    - Douglas Adams
    The Hitchhiker's Guide to the Galaxy

  3. #3
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    that happens because the server thinks that &b=two
    is part of the query string being sent to the redirect.asp
    document

    try this:
    Code:
    <%
    url = Request("url")
    endofurl = request("b")
    response.write url & "&b=" & endofurl
    %>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width