ZennoLab Assemblies Documentation
GetCookie Method
Example 
ZennoLab.CommandCenter Namespace > Instance Class : GetCookie Method

Type: System.String

The domain of cookie. The default value is empty string.

Type: System.Boolean

The true, if need format of cookie "name1=value1; name2=value2; ...", otherwise false. The default value is false. The default format is "Host\tDomainFlag\tPath\tSecureFlag\tExpiry\tName\tValue\tHttpOnlyFlag\tSessionFlag\r\n ..."

Gets cookie.
Syntax
public string GetCookie( 
   string domain,
   bool isCookieFormat
)

Parameters

domain

Type: System.String

The domain of cookie. The default value is empty string.

isCookieFormat

Type: System.Boolean

The true, if need format of cookie "name1=value1; name2=value2; ...", otherwise false. The default value is false. The default format is "Host\tDomainFlag\tPath\tSecureFlag\tExpiry\tName\tValue\tHttpOnlyFlag\tSessionFlag\r\n ..."

Return Value

Type: System.String

The cookies in the string format.

Example
The following example uses the GetCookie method.
instance.ActiveTab.Navigate("http://google.com/");
instance.ActiveTab.WaitDownloading();
// get cookie by domain
return instance.GetCookie("google.com", true);
$instance->ActiveTab->Navigate("http://google.com/");
$instance->ActiveTab->WaitDownloading();
// get cookie by domain
return $instance->GetCookie("google.com", true);
Requirements

Target Platforms: Desktop: Windows XP SP3 and older. Server: Windows Server 2003 and older.

See Also

Reference

Instance Class
Instance Members
ClearCookie Method
LoadCookie Method
SaveCookie Method
SetCookie Method