c# - Page redirects to subdomain folder -


i have code redirects user when sign out:

   if (isrequestedpage("login") && authorization.isauthenticated())             {                 response.redirect("calendarview.aspx");             }             else if (libkezberprojectmanager.data.context.needsfirstuse() && !isrequestedpage("firstuse"))             {                 response.redirect("firstuse.aspx");             }             else if (!authorization.isauthenticated() && !isrequestedpage("login") && !libkezberprojectmanager.data.context.needsfirstuse())             {                 string filename = this.page.request.url.tostring();                 filename = filename.remove(0, filename.lastindexof("/") + 1);                  response.redirect("login.aspx?redirect=" + filename);             }         }         public bool isrequestedpage(string pagename)         {             return request.rawurl.contains(pagename + ".aspx");         }    protected void lnksignout_click(object sender, eventargs e) {     authorization.logout();     response.redirect("login.aspx?logout=true"); } 

when sign out, in pages, instead of bringing me to:

kezblu.mysite.com/login.aspx?logout=true 

i end at:

kezblu.mysite.com/kezblu/login.aspx?logout=true 

i have no way debug locally... not have iis server.

what might cause this?

it should redirect kezblu.mysite.com/destination.aspx

i not have code appends subdomain directory.

thanks

have tried using response.redirect("~/login.aspx?logout=true") instead?

the ~/ prefix corresponds root of web application.


Popular posts from this blog

How to calculate SNR of signals in MATLAB? -

c# - Attempting to upload to FTP: System.Net.WebException: System error -

ios - UISlider customization: how to properly add shadow to custom knob image -