Explore Courses Blog Tutorials Interview Questions
0 votes
in DevOps and Agile by (19.7k points)

I get an element like

cv_upload = driver.find_element_by_id('id_cv_upload')

So I want to set its display as inline in python it possible with python to set the display. I tried = "inline"

which is showing me an error.

One way which is getting into my mind is to use Jquery to change the display and then execute it using the driver.execute but unfortunately, I am not getting the right syntax to do this. Let me know how to do this (The syntax.) Thanks.

1 Answer

0 votes
by (62.9k points)

Finally find out the way to set display of an element.


Basically by using a JavaScript code driver.execute_script helps in setting the style of an element.

If you are interested to learn Selenium on a much deeper level and want to become a professional in the testing domain, check out Intellipaat’s Selenium online training!

Browse Categories