Xpath for a div specifying a class and just one style attribute

Viewed 17906

I want to write an xpath to identify a div which has the class foo and the display: block. I wrote

div[@class="foo" and @style="*display: block*"]

but it doesn't work. Is it correct to use and? is it correct to use asterisks like in regex expressions?

1 Answers
Related