المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Redirect URL problem



C# Programming
09-03-2009, 08:57 PM
hi all http://www.barakasoft.com/script/Forums/Images/smiley_smile.gif ,

this my codebehind on login button click
FormsAuthentication.Initialize();
FormsAuthenticationTicket ObjTicket = new FormsAuthenticationTicket(1, txtLoginId.Text, DateTime.Now, DateTime.Now.AddMinutes(60), false, txtLoginId.Text + "," + txtPassword.Text, FormsAuthentication.Forms******Path);
string encTicket = FormsAuthentication.Encrypt(ObjTicket);
string sLoginId = txtLoginId.Text;
sLoginId = sLoginId.Replace(" ", "");

Response.******s.Add(new Http******(FormsAuthentication.Forms******Name, encTicket));
Response.Redirect(FormsAuthentication.GetRedirectUrl(txtLoginId.Text, false)+"?id="+txtLoginId.Text);


and this is web config code








above code well working on local host .......but on live host
"~/" append with url
for example i want
www.abc.com/abc/PresentationLayer/Forms/Main.aspx
but i get
www.abc.com/abc/~/PresentationLayer/Forms/Main.aspx

can anybody tell me that where is problem