User Tools

Site Tools


en:objects:listbox:select:select_index_by_attribute

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
en:objects:listbox:select:select_index_by_attribute [2020/10/13 14:41]
sales created
en:objects:listbox:select:select_index_by_attribute [2026/08/05 22:45] (current)
Line 1: Line 1:
-<html><h2>select_index_by_attribute</h2> <strong>select_index_by_attribute($attr_name,attr_value,$exactly,$index,$frame=-1);</strong> - this function is used to select an option with the specified index in the ListBox, finding it by the specified attribute value or part of it. <br><br>the input Function accepts parameters:<br><br><li><font color=green>$attr_name</font> – name of the attribute whose value we will search for the element on the page (string). To find out the attribute names of an element, you can use either the element inspector, the context menu, or view it in the list of elements.<br><li><font color=green>$attr_value</font> – the value of the attribute that we will use to search for the element on the page (string). To find out the value of a given attribute for an element, you can use either the element inspector, the context menu, or view it in the list of elements.<br><li><font color=green>$exactly</font> – exact match of the value of the specified attribute when searching for an element (boolean), by default <font color=blue>1</font> - the value of the specified element attribute must completely match the passed parameter (<font color=green>$attr_value</font>). if this parameter is set as <font color=blue>0</font>, the first element is found where the specified attribute value contains the specified string (<font color=green>$attr_value</font>).Starting from version 7.0.25, you can fart the value <font color=blue>2</font>, then attr_value will be interpreted as a regular expression for the Java Script String.search function.<li><font color=green>$index</font> – index of the option, numbering starts from zero (int) <li><font color=green>$frame</font> – the number of the frame in which we are looking for the element (string). Frame numbers start from zero. By default, <font color=blue>-1</font> - the element is not in the frame. You can find out the number of the frame that contains the item you need from the task inspector, the context menu, and the item list panel. <br> With version 4.6.41 of postpone: you can pass nested frames, the principle is the same, a string is numbered frames separated by <font color=blue>:</font> for example, if you transfer <font color=blue>"1:0:5"</font> - will the selected frame number <font color=blue>1</font> in it under the frame with the number <font color=blue>0</font> and the subframe number <font color=blue>5</font><br> Since version 7.0.38, you can pass "url=>XXX", then search for the frame that contains the specified src, or pass "name=>XXX" - then the frame will be searched by the specified part of the name.<br><br>After the function returns the result of their work in the script (the return value type is boolean):<br><li><font color=blue>true</font> – executed successfully<li><font color=blue>false</font> to find this element failed (e.g. no items that meet the specified criteria or not this frame)<br><br></html>+<html><h2>select_index_by_attribute</h2> <strong>select_index_by_attribute($attr_name,$attr_value,$exactly,$index,$frame=-1);</strong> - this function is used to select an option with the specified index in the ListBox, finding it by the specified attribute value or part of it. <br><br>the input Function accepts parameters:<br><br><li><font color=green>$attr_name</font> – name of the attribute whose value we will search for the element on the page (string). To find out the attribute names of an element, you can use either the element inspector, the context menu, or view it in the list of elements.<br><li><font color=green>$attr_value</font> – the value of the attribute that we will use to search for the element on the page (string). To find out the value of a given attribute for an element, you can use either the element inspector, the context menu, or view it in the list of elements.<br><li><font color=green>$exactly</font> – exact match of the value of the specified attribute when searching for an element (boolean), by default <font color=blue>1</font> - the value of the specified element attribute must completely match the passed parameter (<font color=green>$attr_value</font>). if this parameter is set as <font color=blue>0</font>, the first element is found where the specified attribute value contains the specified string (<font color=green>$attr_value</font>).Starting from version 7.0.25, you can fart the value <font color=blue>2</font>, then attr_value will be interpreted as a regular expression for the Java Script String.search function.<li><font color=green>$index</font> – index of the option, numbering starts from zero (int) <li><font color=green>$frame</font> – the number of the frame in which we are looking for the element (string). Frame numbers start from zero. By default, <font color=blue>-1</font> - the element is not in the frame. You can find out the number of the frame that contains the item you need from the task inspector, the context menu, and the item list panel. <br> With version 4.6.41 of postpone: you can pass nested frames, the principle is the same, a string is numbered frames separated by <font color=blue>:</font> for example, if you transfer <font color=blue>"1:0:5"</font> - will the selected frame number <font color=blue>1</font> in it under the frame with the number <font color=blue>0</font> and the subframe number <font color=blue>5</font><br> Since version 7.0.38, you can pass "url=>XXX", then search for the frame that contains the specified src, or pass "name=>XXX" - then the frame will be searched by the specified part of the name.<br><br>After the function returns the result of their work in the script (the return value type is boolean):<br><li><font color=blue>true</font> – executed successfully<li><font color=blue>false</font> to find this element failed (e.g. no items that meet the specified criteria or not this frame)<br><br></html>
  
 PHP example: <code php><?php $xhe_host = "127.0.0.1:7014"; PHP example: <code php><?php $xhe_host = "127.0.0.1:7014";
en/objects/listbox/select/select_index_by_attribute.1602589279.txt.gz · Last modified: 2020/10/13 14:41 by sales