Roles.CookiePath 속성

정의

캐시된 역할 이름 쿠키에 대한 경로를 가져옵니다.

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

속성 값

String

역할 이름이 캐시되는 쿠키의 경로입니다. 기본값은 /입니다.

예제

다음 예제에서는 ASP.NET 애플리케이션에 system.web 대한 Web.config 파일의 섹션에 있는 roleManager 요소를 보여줍니다. 애플리케이션에서는 지정는 SqlRoleProvider 집합과 인스턴스는 cookiePath /MyApplication 특성입니다.

<roleManager defaultProvider="SqlProvider"
  enabled="true"
  cacheRolesInCookie="true"
  cookieName=".ASPROLES"
  cookieTimeout="30"
  cookiePath="/MyApplication"
  cookieRequireSSL="false"
  cookieSlidingExpiration="true"
  cookieProtection="All" >
  <providers>
    <add
      name="SqlProvider"
      type="System.Web.Security.SqlRoleProvider"
      connectionStringName="SqlServices"
      applicationName="MyApplication" />
  </providers>
</roleManager>

설명

역할 캐시 되는 쿠키의 경로 설정 하 여 애플리케이션에 대해 지정할 수 있습니다는 cookiePath ASP.NET 애플리케이션의 Web.config 파일에는 특성입니다. 쿠키 경로에 대한 자세한 내용은 다음을 참조하세요 Path.

적용 대상

추가 정보