Note that there are some explanatory texts on larger screens.

plurals
  1. POGet values from a select list using xpath
    primarykey
    data
    text
    <p>I'm trying to get the select list values using xpath because by id is giving me false in the exists function, but is not working</p> <pre><code>puts $browser.select_list(:xpath,"//*[@id='numType']").exists? number = $browser.select_list(:xpath,"//*[@id='numType']").options.map(&amp;:text) number_list = Array.new number.each do |number_text| number_list &lt;&lt; "#{number_text}" end </code></pre> <p>HTML code:</p> <pre><code>&lt;div id="forwardRs"&gt; &lt;div class="forwardR"&gt; &lt;div id="forwardT" class="rc1"&gt; &lt;select id="forward_types" name="Foward Types" tabindex="5" onchange="changeForwardTypes(this);"&gt; &lt;option value="unconditional"&gt;unconditional&lt;/option&gt; &lt;option value="busy"&gt;busy&lt;/option&gt; &lt;option value="reply"&gt;reply&lt;/option&gt; &lt;option value="reachable"&gt;reachable&lt;/option&gt; &lt;option value="other"&gt;other&lt;/option&gt; &lt;/select&gt; &lt;/div&gt; &lt;div id="numtype" class="rc1" style=""&gt; &lt;select id="numType" onchange="changeNumType(this);" name="numbers" tabindex="5"&gt; &lt;option value="ex"&gt;Ex&lt;/option&gt; &lt;option value="in"&gt;In&lt;/option&gt; &lt;/select&gt; &lt;/div&gt; &lt;div id="rule" class="rc1" style=""&gt; &lt;input id="tel" type="text" value="" size="20" name="tel" tabindex="2" onchange="changeNumberRule(this);"&gt; &lt;/div&gt; &lt;div id="removeForwardRule" class="rc3"&gt; &lt;a onclick="removeForwardRule(this);"&gt; &lt;img src="../../images/delete.png"&gt; &lt;/a&gt; </code></pre> <p> </p> <p>How can i do this?</p> <p>Tanks</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload