HTTP_X_REWRITE_URL

Helicon Ape provides support for Apache .htacces and .htpasswd configuration files for Microsoft IIS.
User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

HTTP_X_REWRITE_URL

03 May 2013, 05:08

I understand that the server variable HTTP_X_REWRITE_URL does not exist in IIS6, is there another way to get the pre-translated url to my asp pages?

At the moment I have ISAPIRewrite installed with no rules just so that I can have this functionality in IIS6.

I use this on my site, its to remember the previous page visited for the shopping cart. Some of my pages use Response.Redirect which stops the referrer server variable from working.

Cheers,

Steve

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: HTTP_X_REWRITE_URL

03 May 2013, 18:50

Hello,

What makes you think so? http://www.helicontech.com/isapi_rewrite/doc/concept.htm


Regards
Andrew

User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

Re: HTTP_X_REWRITE_URL

07 May 2013, 05:21

Hi Andrew,
I recently migrated from ISAPI Rewrite 3 to Ape, you kindly helped me get up and running. I use HTTP_X_REWRITE_URL extensively on my site and have found that once I removed ISAPI Rewrite 3 this Server Variable now returns nothing. I found several other posts saying the same thing, along with a fix. Sadly the fix does not work on IIS 6 or when IIS7 is used in Classic Mode.

I have also tried to use REQUEST_URI but that is returning nothing as well.

I have looped through (in Classic ASP) all the available server variables and none of them return the original URL.

I can not uninstall ISAPI Rewrite until I have found a solution to this.

My comment about Repsonse.Redirect not setting the referrer is true, but nothing to do with your products.

Fron http://www.w3schools.com/asp/coll_servervariables.asp :

HTTP_REFERER - Returns a string containing the URL of the page that referred the request to the current page using an <a> tag. If the page is redirected, HTTP_REFERER is empty

This is why I set a session variable on every page that contains its full url, so the next page can easily use this if needed to go back to the previous page.

Steve

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: HTTP_X_REWRITE_URL

08 May 2013, 09:23

Well, it is there. You just need to make sure to have "Options all" - http://www.helicontech.com/ape/doc/mod_core.htm

Regards
Andrew

User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

Re: HTTP_X_REWRITE_URL

08 May 2013, 09:45

Hi Andrew,
I already have this in my httpd.conf: Options All -StopOnError

Still not getting a value for HTTP_X_REWRITE_URL.

Should I change it to something else?

Steve

User avatar
Posts: 28
Joined: 02 Mar 2012, 12:50

Re: HTTP_X_REWRITE_URL

11 May 2013, 06:43

Looks like Ape not functioning.
Please double check that Ape registered properly:
- run Ape Manager
- select target site
- right click
- enable Ape

also check error.log in Ape folder

User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

Re: HTTP_X_REWRITE_URL

13 May 2013, 05:11

Hi Sergey,
Ape is most certainly running, I have a whole load of db map files working for several sites doing all the redirects and url rewriting. Everything is working except this one thing.

Nothing in the log files either.

Please note, this is IIS6 on Windows 2003. Ape is version 3.1.0.100.

According to this I won't get this working on IIS6: http://www.helicontech.com/forum/15523-How_do_I_get_HTTP_X_REWRITE_URL_using_ape.html

Steve

User avatar
Posts: 871
Joined: 12 Mar 2012, 09:54

Re: HTTP_X_REWRITE_URL

14 May 2013, 07:34

Hello, Steve

Sorry to mislead you. We've checked the situation and it appears that Ape cannot change headers in win 2003.
Sorry for inconvenience.

User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

Re: HTTP_X_REWRITE_URL

16 May 2013, 06:06

Hi Anton,
So my only option is to leave the free version of ISAPI Rewrite installed to achieve this functionality. I would like to suggest this as a feature that is really needed for Ape on Windows 2003.

In the mean time please update the docs so that this is made clear that it doesn't work on IIS 6.

Cheers,

Steve

User avatar
Posts: 871
Joined: 12 Mar 2012, 09:54

Re: HTTP_X_REWRITE_URL

16 May 2013, 06:22

Hello, Steve

We'll fix the docs for sure, but it's simply impossible to implement that feature for IIS6 + .NET module junction.
Sorry for inconvenience.

User avatar
Posts: 34
Joined: 19 Feb 2013, 11:44

Re: HTTP_X_REWRITE_URL

16 May 2013, 06:25

Hi Anton,
That is a shame, I will just use both until we upgrade to IIS 7.

Steve

Return to Helicon Ape

Who is online

Users browsing this forum: No registered users and 7 guests