POSTBACK CAUSES ORIGINAL URL TO DESPLAY

ISAPI_Rewrite is a powerful URL manipulation engine based on regular expressions
User avatar
Posts: 5
Joined: 24 May 2012, 02:20

POSTBACK CAUSES ORIGINAL URL TO DESPLAY

24 May 2012, 02:22

When any control on a page causes postback
it makes rewrited url back to the actual url

for example i am requesting

www.xyz.com/product.htm

and after a click of a button it shows
www.xyz.com/product.aspx

any help appreciated

thank you

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

Re: POSTBACK CAUSES ORIGINAL URL TO DESPLAY

24 May 2012, 04:12

Hello,

This is actually a normal behavior.
Please try to have the following condition before your rule:

RewriteCond %{REQUEST_METHOD} !^POST

User avatar
Posts: 5
Joined: 24 May 2012, 02:20

Re: POSTBACK CAUSES ORIGINAL URL TO DESPLAY

24 May 2012, 08:31

i tried with this rule
RewriteCond %{REQUEST_METHOD} !^POST

but no luck

User avatar
Posts: 5
Joined: 24 May 2012, 02:20

Re: POSTBACK CAUSES ORIGINAL URL TO DESPLAY

25 May 2012, 03:09

In page_load i wrote and it does the trick
Dim newPageUrl =Request.ServerVariables("HTTP_X_REWRITE_URL").ToString
Context.RewritePath(System.IO.Path.GetFileName(newPageUrl))

Return to ISAPI_Rewrite 2.x

Who is online

Users browsing this forum: No registered users and 10 guests