cookie class : SameSite(string) setter
Description
Set the SameSite attribute.
Syntax
instance.SameSite = value;
Assigned value
Class | Description |
string | A string that represents the SameSite attribute. |
Return value
None.
Sample code
1: | browser br; |
2: | cookie coo = br.GetCookie("Example"); |
3: | coo.SameSite = "Lax"; |
4: | coo.Set(); |
Notes
Specify the SameSite attribute with a string. The setting values are:
Lax
Strict
None
If you set a value other than the above, an exception will occur.
You need to call the Set() method to commit your changes.
Links for reference
None.