c# - loginURL in web.config forms authentication within virtual directory based page -



c# - loginURL in web.config forms authentication within virtual directory based page -

i have application in virtual directory (asp.net 4.0 c#). secured forms authentication. within application sub directories have content tree matches rough order of website

www.server.com/application/sub-directory1/sub-directory2/

<forms name=".adauthcookie" loginurl="login.aspx" slidingexpiration="true" timeout="100" defaulturl="~/default.aspx"/>

what should "loginurl" allow work subdirectory? i.e. if session times out, how can loginurl redirect right place?

if set loginurl="~/login.aspx" , in sub-directory 1, redirects www.server.com/application/sub-directory1/login.aspx not exist. want redirect www.server.com/application/login.aspx

thanks

did configure loginurl within web.config file located @ root folder? if should work. have asp.net 3.5 similar structure. when timeout within http://localhost/providence /member/mail/newmessage.aspx, redirected http://localhost/providence/login.aspx?returnurl=%2fprovidence%2fmember%2fmail%2fnewmessage.aspx.

i have not tried asp.net 4.0 though.

c# asp.net forms-authentication

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -