3 ms·
Even if you're not using the name in the form data you're still giving it meaning and importance by using it in a locator - you're saying "find the specific ele
by onion2k 10y ago
Even if you're not using the name in the form data you're still giving it meaning and importance by using it in a locator - you're saying "find the specific element in the page that has the name 'FullName'". If you don't actually care what the name is then you should use something else, like an ID attribute.
- moogly 10y agoSure, I don't necessarily disagree with the sentiment you're expressing, I'm just saying that today, HTML forms aren't as tied to the backend as they used to be. Though personally I wouldn't want to have to start adding ids and names to things in the markup just for Selenium to find them.