humanemulator.net — справка.
Продукт, демо и покупка — на
хуманэмулятор.рф
|
Демо
|
Купить
|
API
|
лог изменений
check_all
check_all($check=true,$frame="-1"); - Отметить DOM элемент чекбокс все элементы (без учета проверки: существует ли элемент)Функция на вход принимает параметры:
После выполнения функции возвращаемое значение будет равно одному из двух :
Пример использования
<?php // Scenario: Check or uncheck radio buttons on a page // Description: Demonstrates how to check or uncheck radio buttons on a page // Classes used: DOM, XHERadioButton, XHEBrowser, XHEApplication $xhe_host = "127.0.0.1:7010"; if (!isset($path)){ // Path to the init.php file for connecting to the XHE API $path = "../../../Templates/init.php"; // Including init.php grants access to all classes and functionality for working with the XHE API require($path); } // Navigate to test page with radio buttons $pageUrl = TEST_POLYGON_URL . "radiobutton.html"; echo("Navigate to HTML page: $pageUrl\n"); WEB::$browser->navigate($pageUrl); WEB::$browser->wait_js(); // Example 1: Check radio button by name $name = "basic_radio"; $check = true; echo("\nExample 1: Check radio button with name '$name'\n"); $checkResult = DOM::$radiobox->check_by_name($name, $check); echo("Check by name result: " . ($checkResult ? "success" : "failed") . "\n"); // Example 2: Uncheck radio button by name $name = "basic_radio"; $check = false; echo("\nExample 2: Uncheck radio button with name '$name'\n"); $checkResult = DOM::$radiobox->check_by_name($name, $check); echo("Uncheck by name result: " . ($checkResult ? "success" : "failed") . "\n"); // Example 3: Check radio button by number $number = 1; $check = true; echo("\nExample 3: Check radio button with number '$number'\n"); $checkResult = DOM::$radiobox->check_by_number($number, $check); echo("Check by number result: " . ($checkResult ? "success" : "failed") . "\n"); // Note: For radio buttons, checking all will typically result in only the last one being checked // since radio buttons with the same name are mutually exclusive // Quit the application WINDOW::$app->quit();
=============================================
Radiobox Объекты DOM System Vision Web Window
=============================================
Если что-то непонятно или необходимо узнать или считаете что надо добавить по работе этой функции, пишите в комментарии или на наш форум.