Skip to content

WebDriver Command Reference

robocoder edited this page May 21, 2012 · 2 revisions

Application Cache

Get application cache status

Example:

$status = $session->application_cache()->status();

Returns: integer

Application status codes

0 uncached 1 idle 2 checking 3 downloading 4 update ready 5 obsolete

Execute SQL

Example:

$result = $session->execute_sql(array( 'dbName' => $dbname, 'query' => $query, 'args' => $args, ));

Returns: array

array( 'insertId' => ..., 'rowsAffected' => ..., 'rows' => ..., )

Get browser connection state

Example:

$state = $session->getBrowser_connection();

Returns: boolean

True if application is online; false otherwise

Set browser connection state

Example:

$session->postBrowser_connection(array( 'state' => $onlineState, // boolean ));

Upload file

Example:

$session->file(array( 'file' => $filename, ));

Returns: string Absolute path of file

Get logs

Example:

$logs = $session->log(array( 'type' => 'driver', ));

Returns: array

array( array( 'level' => ..., 'timestamp' => ..., 'message' => ..., ), ... )

Clone this wiki locally