Quantcast
Channel: Active questions tagged selenium - Stack Overflow
Viewing all articles
Browse latest Browse all 98807

Why is Selenium is giving me a case insensitive Style attribute?

$
0
0

I'm trying to get the "Style" attribute from the following item:

<td rowspan="31" style="background-color:Transparent;min-width: 19.14mm;WIDTH:21.26mm;" class="Ac165936899664594908cfec8fa25b2a0270c" height="548"><div style="word-wrap:break-word;white-space:pre-wrap;" class="Ac165936899664594908cfec8fa25b2a0270"> XXXXX </div></td>

But when I use the following command:

driver.find_element_by_xpath("//a[@tabindex='"+str(m)+"']/../../following-sibling::td[2]").get_attribute('style')

Selenium is giving me:

'background-color: transparent; min-width: 19.14mm; width: 21.26mm;'

instead of

'background-color:Transparent;min-width: 19.14mm;WIDTH:21.26mm;'


Viewing all articles
Browse latest Browse all 98807


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>