Quote: apparently the value for the 'friends' button differs from one account to anotherIf i go to my account and inspect the friends button on multiple accounts the link is always with the class name of
_6-6
. Also are you adding a delay? You need to make sure the you finished logging in before trying to click a button on the following page. To use it headless you would use PhantomJS instead of Chrome or Firefox. Its just that though, headless, it is still loading the page and takes about the same time. This is required though for javascript as python cannot really get around that. And facebook has plenty of that.
You can use straight python to connect, but you are going to run into a lot of hindrances. They purposely have anti-bot measures, and obfuscate their code to stop you from doing this, and not to mention the big one...javascript.
Recommended Tutorials: