Using selenium in order to read emails on gmail
问题 I'm using selenium-rc and I'm trying to click on a specific email on gmail in order to get into the email page. More specifically: on the gmail inbox, click on a email with a specific subject. I can't find the correct xpath (none of the tags in the email part are links). Ideas? 回答1: This XPath should do the trick: //div[@class = 'y6']/span[contains(., 'subject_here')] ... provided that you've first changed to the canvas_frame frame. Otherwise, it's unlikely it'll work at all. If you're not