Kev 69 Posted January 1, 2012 Report Share Posted January 1, 2012 Hi all, Happy New Year. I am creating a bot that will log into the WarriorForum and go to the online.php section which shows me who is online at the current moment in time. I would like to capture the table of results for each page, including the username, IP and time plus what page they are on. Here's the code I have created for it: ui text box("Username", #username) ui text box("Password", #password) ui text box("Starting Page", #page) define WarriorLogin { navigate("http://www.warriorforum.com/online.php", "Wait") type text($element offset(<username field>, 1), #username, "Standard") type text($element offset(<password field>, 1), #password, "Standard") click($element offset(<login button>, 1), "Left Click", "No") wait(5) navigate("http://www.warriorforum.com/online.php?order=asc&sort=username&pp=200&page={#page}", "Wait") } define Scraping table { set table cell(&wsotabledata, 0, 1, "") loop(10) { scrape table(<innertext="01:31 PMiamhelping">, &wsotabledata) add item to list(%wsodata, &wsotabledata, "Delete", "Global") wait(4) increment(#page) navigate("http://www.warriorforum.com/online.php?order=asc&sort=username&pp=200&page={#page}", "Wait") } Log Out() } WarriorLogin() Now, I can get it working but a couple of things I am having an issue with are: It will only scrape the info on the first page. I can make it go to the next page but increment page by one then navigate to the new page url. But scraping this page returns nothing. I have played around with wildcards etc but just do not know which attribute to select. Also, I would much rather the bot navigate to the last page rather than me creating a loop. How can I do this? Notive that I have an option to start at a page - select 1 for the start. If you use the Warrior forum simply use your login info in the bot. I hope you can help me out - been wrecking my head getting this sorted. Cheers Quote Link to post Share on other sites
JohnB 255 Posted January 1, 2012 Report Share Posted January 1, 2012 It looks like something's up with WF at the moment. I am unable to log in. As soon as I can, I will have a look. John Quote Link to post Share on other sites
LoWrIdErTJ - BotGuru 904 Posted January 1, 2012 Report Share Posted January 1, 2012 Keep in mind john when i was testing that one active users list bot i made for WF, that you cant navigate directly to the home page in ubot. you have to go to another page first then you can click to the home page, or whatever page your wanting. Quote Link to post Share on other sites
JohnB 255 Posted January 1, 2012 Report Share Posted January 1, 2012 Yeah...I couldn't log in at all, even in the browser. I'm in now though. John Quote Link to post Share on other sites
Kev 69 Posted January 1, 2012 Author Report Share Posted January 1, 2012 Thanks John, appreciate the help with this Quote Link to post Share on other sites
JohnB 255 Posted January 1, 2012 Report Share Posted January 1, 2012 Are you able to see the who's online page in WF (in the UBot browser)? It doesn't load for me. John Quote Link to post Share on other sites
Kev 69 Posted January 1, 2012 Author Report Share Posted January 1, 2012 No John not currently. It seems to be fine in the mornings say 11 est but now it's not online Quote Link to post Share on other sites
LoWrIdErTJ - BotGuru 904 Posted January 1, 2012 Report Share Posted January 1, 2012 It might be that it gets disabled in peak hours. Would be better if you watched the online area on the home page, and monitor it to get the desired results. For instance I would over 15,000 active members on WF forums that was verified online over a 1 week period. Theses aren't new sign ups, as it requires them to login and navigate around the site to set online status. They are active members on the forum. and had logged in, and was navigating the site. The bot I built scanned and removed duplicates every 5 minutes over a 7 day period of time. TJ Quote Link to post Share on other sites
Kev 69 Posted January 1, 2012 Author Report Share Posted January 1, 2012 Good idea TJ but here's the reason for the other way I wanted to trick the IP of the usernames in order to find duplicate ips and multiple usernames, in a bid to help me figure out who's double accounting. I know folks would probably use proxies but this would be a nice way to catch the noobs/chancers and then simply publish a page with the info Quote Link to post Share on other sites
LoWrIdErTJ - BotGuru 904 Posted January 2, 2012 Report Share Posted January 2, 2012 I gotcha.. nice idea.. Quote Link to post Share on other sites
JohnB 255 Posted January 2, 2012 Report Share Posted January 2, 2012 Ok, You can give this a try: If it is only for a single page, you can run it as is. If you need to run it in a loop then put the clear list commands inside the loop, but keep the add list to table as column commands outside the loop. Also I changed the nav when I was having trouble viewing the page...you string with the variable is fine (I just forgot to put it back). This code worls for the last page: <title=w"Last Page - *"> (in a click command) Johnwf_members.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.