Savkeeeee
Savkeeeee

Reputation: 33

Refering to a table without class/id

I want to refer to a table by using beautifulsoup and python 3, but the table doesn't has a class nor id. this is the html of the top layer. how can I identify the table?

Upvotes: 0

Views: 43

Answers (1)

this.girish
this.girish

Reputation: 1306

you can refer table without id/class using xpath

//*[./text()="SKU#"]/ancestor::table[1]

hope this resolves

Upvotes: 1

Related Questions