Combine XPATH predicate with position

后端 未结 3 1999
醉梦人生
醉梦人生 2020-12-30 12:55

I have a collection of div elements that have the class media-gallery-item.
I would like to select element number x.

When just selecting all items,

3条回答
  •  灰色年华
    2020-12-30 13:43

    It looks like your accessing attributes in the wrong way. Try to use

    /div[@id='content-area' and @class='media-gallery-item'][2]
    

提交回复
热议问题