FormsAuthentication.FormsCookiePath Propriedade

Definição

Obtém o caminho para o cookie de autenticação de formulários.Gets the path for the forms-authentication cookie.

public:
 static property System::String ^ FormsCookiePath { System::String ^ get(); };
public static string FormsCookiePath { get; }
member this.FormsCookiePath : string
Public Shared ReadOnly Property FormsCookiePath As String

Valor da propriedade

String

O caminho do cookie no qual as informações do tíquete de autenticação de formulários estão armazenadas.The path of the cookie where the forms-authentication ticket information is stored. O padrão é "/".The default is "/".

Exemplos

O exemplo de código a seguir define o FormsCookiePath valor da propriedade usando o path atributo no arquivo Web.config.The following code example sets the FormsCookiePath property value by using the path attribute in the Web.config file.

<authentication mode="Forms">
  <forms loginUrl="member_login.aspx"
    cookieless="UseCookies"
    path="/MyApplication" />
</authentication>

Comentários

O FormsCookiePath valor da propriedade é definido no arquivo de configuração para um aplicativo ASP.NET usando o path atributo do elemento de configuração de formulários .The FormsCookiePath property value is set in the configuration file for an ASP.NET application using the path attribute of the forms configuration element. O FormsCookiePath especifica o Path para o cookie que armazena as FormsAuthenticationTicket informações.The FormsCookiePath specifies the Path for the cookie that stores the FormsAuthenticationTicket information.

Aplica-se a