\WebDriverTargetLocator

Used to locate a given frame or window.

Summary

Methods
Properties
Constants
__construct()
defaultContent()
frame()
window()
alert()
No public properties found
No constants found
No protected methods found
$executor
$driver
N/A
No private methods found
No private properties found
N/A

Properties

$executor

$executor : 

Type

$driver

$driver : 

Type

Methods

__construct()

__construct(  $executor,   $driver) 

Parameters

$executor
$driver

defaultContent()

defaultContent() : \WebDriver

Switch to the main document if the page contains iframes. Otherwise, switch to the first frame on the page.

Returns

\WebDriver —

The driver focused on the top window or the first frame.

frame()

frame(\WebDriverElement|string  $frame) : \WebDriver

Switch to the iframe by its id or name.

Parameters

\WebDriverElement|string $frame

The WebDriverElement, the id or the name of the frame.

Returns

\WebDriver —

The driver focused on the given frame.

window()

window(string  $handle) : \WebDriver

Switch the focus to another window by its handle.

Parameters

string $handle

The handle of the window to be focused on.

Returns

\WebDriver —

Tge driver focused on the given window.

alert()

alert() : \WebDriverAlert

Switch to the currently active modal dialog for this particular driver instance.

Returns

\WebDriverAlert