J
John Knoop
Hi
Suppose this page is currently loaded: http://localhost/myapp/?page=news
Default.aspx in the Myapp folder will then include /news/default.aspx.
In the file /news/default.aspx there is a <asp:button> that triggers
Sub_MyClick. But instead of reloading the same page
(http://localhost/myapp/?page=news), it jumps to
http://localhost/myapp/news/default.aspx.
How to prevent this? I've tried to add the following code to global.asax...
Sub Application_EndRequest(Sender As Object, e As EventArgs)
If Request.IsAuthenticated And Request.Filepath <> "/myapp/Default.aspx"
And IsNothing(Request.Form("__VIEWSTATE")) = False Then Response.Redirect
(request.urlreferrer.absoluteuri)
End Sub
....but that only created other problems.
Anyone?
Suppose this page is currently loaded: http://localhost/myapp/?page=news
Default.aspx in the Myapp folder will then include /news/default.aspx.
In the file /news/default.aspx there is a <asp:button> that triggers
Sub_MyClick. But instead of reloading the same page
(http://localhost/myapp/?page=news), it jumps to
http://localhost/myapp/news/default.aspx.
How to prevent this? I've tried to add the following code to global.asax...
Sub Application_EndRequest(Sender As Object, e As EventArgs)
If Request.IsAuthenticated And Request.Filepath <> "/myapp/Default.aspx"
And IsNothing(Request.Form("__VIEWSTATE")) = False Then Response.Redirect
(request.urlreferrer.absoluteuri)
End Sub
....but that only created other problems.
Anyone?