-
-
Notifications
You must be signed in to change notification settings - Fork 11
libcURL.CookieEngine.SetCookie
libcURL.CookieEngine.SetCookie
Function SetCookie(Name As String, Value As String, Domain As String, Expires As Date = Nil, Path As String = "", HTTPOnly As Boolean = False) As Boolean
Function SetCookie(RawCookie As String) As Boolean
Name | Type | Comment |
---|---|---|
Name | String | The name of the cookie. |
Value | String | The value of the cookie. |
Domain | String | The domain of the cookie. |
Expires | Date | Optional. If specified, the expiration date of the cookie. |
Path | String | Optional. If specified, the remote path of the cookie. |
HTTPOnly | Boolean | Optional. If True , the HTTP-only attribute of the cookie is set. |
Name | Type | Comment |
---|---|---|
RawCookie | String | A raw cookie string. |
Returns true if the operation succeeded; if it returns false then check EasyHandle.LastError.
Sets a cookie for the cookie engine to use. If a cookie with the same name and domain already exists it will be updated. If no domain is specified then the cookie will be sent with all transfers and cannot be modified by a server-set cookie; always specify a domain if more than one server will be contacted.
When setting a raw cookie string, you may pass either Netscape cookie jar lines or HTTP Set-Cookie
header lines. (See: CookieEngine.StringValue for details.)
If no expiration date is specified then the cookie will be a "session" cookie.
Wiki home | Project page | Bugs | Become a sponsor
Text and code examples are Copyright ©2014-24 Andrew Lambert, offered under the CC BY-SA 3.0 License.