Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set value of input without name attribute #31

Closed
kraai opened this issue Jun 17, 2018 · 1 comment
Closed

Set value of input without name attribute #31

kraai opened this issue Jun 17, 2018 · 1 comment

Comments

@kraai
Copy link
Contributor

kraai commented Jun 17, 2018

Please add a method for setting the value of an input element that doesn't have a name attribute.

I'm trying to set the value of the input element whose id is autocomplete2 on https://www.reservecalifornia.com/CaliforniaWebHome/Facilities/AdvanceSearch.aspx. The element doesn't have a name attribute, so Form::set_by_name doesn't seem to work. Client::find can find the element, but Element doesn't appear to have a method for setting its value.

@jonhoo
Copy link
Owner

jonhoo commented Jun 18, 2018

Ah, yes you're right. There should probably be a set method that takes a Locator. Adding this should probably be pretty straightforward. You should be able to copy/paste set_by_name, and make it take a Locator instead (the first two lines would then go away). You could then change set_by_name to call set. Think you could submit a PR?

kraai added a commit to kraai/fantoccini that referenced this issue Jun 18, 2018
@kraai kraai mentioned this issue Jun 18, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants