HttpCookie.Path プロパティ

定義

現在のクッキーを使用して送信する仮想パスを取得または設定します。

public:
 property System::String ^ Path { System::String ^ get(); void set(System::String ^ value); };
public string Path { get; set; }
member this.Path : string with get, set
Public Property Path As String

プロパティ値

クッキーを使用して送信する仮想パス。 既定は / (サーバー ルート) です。

次のコード例では、新しい Cookie の Path プロパティを設定します。

MyCookie.Path = "/asp";

MyCookie.Path = "/asp"
 

注釈

プロパティは Path 、 プロパティを Domain 拡張して、Cookie が適用される特定の URL を完全に記述します。 たとえば、URL http:/www.microsoft.com/aspでは ドメインは で、パスは www.microsoft.com /asp です。

適用対象

こちらもご覧ください