Platforms to show: All Mac Windows Linux Cross-Platform

NSHTTPCookieMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Cocoa Networking MBS MacControls Plugin 11.1 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
An NSHTTPCookie object represents an HTTP cookie.
Example
// query list of all cookies in shared storage
dim cookies(-1) as NSHTTPCookieMBS = NSHTTPCookieStorageMBS.sharedHTTPCookieStorage.cookies

// we collect domain names
dim domains(-1) as string
for each cookie as NSHTTPCookieMBS in cookies
if domains.IndexOf(cookie.domain) < 0 then
domains.Append cookie.domain
end if
next

// and display them
MsgBox "You have cookies from this domains: "+Join(domains, ", ")

It's an immutable object initialized from a dictionary containing the cookie attributes.

Two versions of cookies are supported:

Version 0: This version refers to "traditional" or "old-style" cookies, the original cookie format defined by Netscape. The majority of cookies encountered are in this format.
Version 1: This version refers to cookies as defined in RFC 2965, HTTP State Management Mechanism.

This class has no sub classes.

Some methods using this class:

Blog Entries

Release notes


The items on this page are in the following plugins: MBS MacControls Plugin.


NSHelpManagerMBS   -   NSHTTPCookieStorageMBS


The biggest plugin in space...