I'm trying to navigate Facebook and access my friends list programatically using WWW::Mechanize::Firefox. I have successfully logged in and navigated to the friends page, but the problem is the friends are not all loaded at once. A portion of them are loaded when the page first loads, and then to get more to load you have to scroll to the bottom of the screen. Getting all friends to load therefore entails repeatedly scrolling to the "new bottom" of the screen each time a new set of friends loads from the previous scroll action. I did some searching on here and saw the suggestion to send javascript through WWW::Mechanize::Firefox, and tried doing this on the friends page:
$mech->eval('window.scrollTo(0, document.body.scrollHeight)');
But that didn't work - instead of scrolling the page down, it took me back to the main page (i.e. the newsfeed). Can anyone give me more detailed information regarding how to programatically scroll the page to the bottom using WWW::Mechanize::Firefox? Thanks
In reply to WWW::Mechanize::Firefox and dynamic pages by Special_K
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |