evp 0 Posted August 16, 2010 Report Share Posted August 16, 2010 I read a .csv file with facebook friends list and then I search for them and ask them for friendship. The problem starts when there are more then 1 friends with that name, a list appear, most of it with the same name. I would like to click the first one. I can't choose the link by attribute cause there are several links that looks the same (e.g., ">user name</a>"). I tried to choose by position but for some mysterious reason it changes one in a while. How can it be done? How I can search for the first occurrence of a certain attribute and click it??? Quote Link to post Share on other sites
MiriamMB 63 Posted August 16, 2010 Report Share Posted August 16, 2010 hmm...if it's a link you are trying to click, there should be an attribute that discerns the first occurrence of the name/username from the second occurrence of the name...are you scraping these names first and then trying to find them? If so maybe that's where you should start, at how you choose the names for scraping. Quote Link to post Share on other sites
evp 0 Posted August 16, 2010 Author Report Share Posted August 16, 2010 hmm...if it's a link you are trying to click, there should be an attribute that discerns the first occurrence of the name/username from the second occurrence of the name...are you scraping these names first and then trying to find them? If so maybe that's where you should start, at how you choose the names for scraping. Nop, Im not scraping them, I have a list of names (csv file) and I search for each name. The problem is that as a result a list of names appear and I need to click the first one. There is in the code some numeric identifier that tells facebook which user ID it is, but doesn't mean anything for me... I'm sure someone somewhere find a way to choose the first occurrence in a page with ubot?? Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.