Platforms to show: All Mac Windows Linux Cross-Platform
Back to ChromiumCookieManagerMBS class.
ChromiumCookieManagerMBS.AllCookies as ChromiumCookieMBS()
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
The returned cookies are ordered by longest path, then by earliest creation date. Returns false (0) if cookies cannot be accessed.
ChromiumCookieManagerMBS.Constructor
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
Can raise exception if no cookie manager is available, e.g. when calling on Linux or Mac OS X or Windows if you don't have the dlls.
May not work if the Chromium was not initialized before by Xojo.
See also:
ChromiumCookieManagerMBS.Constructor(path as string, PersistSessionCookies as Boolean)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 16.4 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
Can raise exception if no cookie manager is available, e.g. when calling on Linux or Mac OS X or Windows if you don't have the dlls.
May not work if the Chromium was not initialized before by Xojo.
See also:
ChromiumCookieManagerMBS.DeleteAllCookies as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
Returns number of deleted cookies.
ChromiumCookieManagerMBS.DeleteCookie(URL as string, CookieName as string) as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
If both url and values cookieName are specified all host and domain cookies matching both will be deleted. If only |url| is specified all host cookies (but not domain cookies) irrespective of path will be deleted. If url is empty all cookies for all hosts and domains will be deleted. Returns false if a non-empty invalid URL is specified or if cookies cannot be accessed.
Returns true on success.
ChromiumCookieManagerMBS.DeleteCookies(URLs() as string, CookieNames() as string) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
Same as DeleteCookie, but with arrays for parameters.
Returns number of successful delete attempts.
ChromiumCookieManagerMBS.DeleteURLCookies(URL as String, HTTPOnly as boolean = false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
The cookies to delete are filtered by the given url scheme, host, domain and path. If includeHttpOnly is true HTTP-only cookies will also be included in the deletion.
Returns number of cookies deleted.
Some examples using this method:
ChromiumCookieManagerMBS.Destructor
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
ChromiumCookieManagerMBS.SetCookie(URL as string, cookie as ChromiumCookieMBS) as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
This function expects each attribute to be well-formed. It will check for disallowed characters (e.g. the ';' character is disallowed within the cookie value attribute) and will return false without setting the cookie if such characters are found.
ChromiumCookieManagerMBS.SetCookies(URL() as string, cookies() as ChromiumCookieMBS) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
Same as SetCookie, but with arrays of URLs and cookie objects.
Returns number of cookies created successfully.
ChromiumCookieManagerMBS.SetStoragePath(Path as string) as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
If path is empty data will be stored in memory only.
Returns false if cookies cannot be accessed.
ChromiumCookieManagerMBS.URLCookies(URL as String, HTTPOnly as boolean = false) as ChromiumCookieMBS()
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | HTMLViewer Win | MBS Win Plugin | 15.2 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop only |
The results are filtered by the given url scheme, host, domain and path. If includeHttpOnly is true HTTP-only cookies will also be included in the results. The returned cookies are ordered by longest path, then by earliest creation date. Returns empty array if cookies cannot be accessed.
Returns nil on any error like low memory.
Some examples using this method:
The items on this page are in the following plugins: MBS Win Plugin.