You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 30, 2023. It is now read-only.
(Mea culpa if this needs to be filed under Ghost Driver, I tried getting a JavaScript test case working to verify on what side of the divide the problem lies, but I was a bit out of my depth.)
Using PhantomJS through Python Selenium bindings I encountered that trying to get the label attribute of an option element yields an empty string with PhantomJS when the attribute has not been explicitly specified in the HTML. Chrome and Firefox work as expected.
I.e. <option>Blah</option> should yield Blah, whereas <option label="Test">Blah</option> should yield Test if asked, in both cases, for the label attribute of <option>.
When rendering a menu choice, user agents should use the value of the label attribute of the OPTION element as the choice. If this attribute is not specified, user agents should use the contents of the OPTION element.
The label attribute provides a label for element. The label of an option element is the value of the label content attribute, if there is one, or, if there is not, the value of the element's text IDL attribute.
The text was updated successfully, but these errors were encountered:
Due to our very limited maintenance capacity, we need to prioritize our development focus on other tasks. Therefore, this issue will be automatically closed (see #15395 for more details). In the future, if we see the need to attend to this issue again, then it will be reopened. Thank you for your contribution!
(Mea culpa if this needs to be filed under Ghost Driver, I tried getting a JavaScript test case working to verify on what side of the divide the problem lies, but I was a bit out of my depth.)
Using PhantomJS through Python Selenium bindings I encountered that trying to get the label attribute of an option element yields an empty string with PhantomJS when the attribute has not been explicitly specified in the HTML. Chrome and Firefox work as expected.
I.e.
<option>Blah</option>
should yieldBlah
, whereas<option label="Test">Blah</option>
should yieldTest
if asked, in both cases, for thelabel
attribute of<option>
.HTML 4.01 specification section on option:
HTML 5 specification section on option:
The text was updated successfully, but these errors were encountered: