Jump to content

how would i get info form a site?


ashley
 Share

Recommended Posts

Here ya go my brother! Is this what you be looking for??

#include <INet.au3>

Global $sStart = 'alt="RuneScape"><br>\n', $sEnd = '\n<iframe style="'

$sHTML = _INetGetSource('http://www.runescape.com/title.ws')
$aArray = StringRegExp($sHTML,'(?s)' & $sStart & '(.*?)' & $sEnd, 3)
MsgBox(0,"Runescape",$aArray[0])

perfect... but now i need to know how meny people in each world..

HERE is how to find:

press: play runescape, now select a detail high or low. then there all there... Also i need the activity

Link to comment
Share on other sites

perfect... but now i need to know how meny people in each world..

That's not going to be so easy, in fact they use javascript on each page which is going to prevent the easy method of using IE.au3 and from using something like
Local $sURL = 'http://www.runescape.com/'

$oIE = _INetGetSource($sURL & 'slj.ws')
$oTable = _IETableGetCollection ($oIE, 1)
$aTableData = _IETableWriteToArray ($oTable)

In fact that table you see is created by more javascript which is

<script type="text/javascript" language="javascript">
var d=document; var r=0; var u="/l0,p-1,j1";
function e(w,m,s,a,h,p,l) {
if (r==0) { d.write("<tr>"); r=1; }
else { d.write("<tr class=r2>"); r=0; }
d.write("<td class="+(m==0?"f":"m")+">");
if (s==0) d.write("<a href=\"http://"+h+".runescape.com"+u+"\">"+"World "+w+"</a>");
else d.write("World "+w);
d.write("</td>");
d.write("<td>"+(s==0?p+" Players":s==1?"OFFLINE":"FULL")+"</td>");
d.write("<td class="+(l==0?"us>US West 1":l==1?"us>US West 2":l==11?"us>US Central 1":l==2?"us>US West 3":l==12?"us>US West 4":l==10?"nl>Netherlands 1":l==5?"uk>UK 1":l==6?"ca>Canada East":l==4?"us>US West 5":l==13?"us>US East 1":l==7?"us>US East 2":l==8?"us>US Central 3":l==9?"us>US Central 2":l==3?"uk>UK 2":l==14?"us>US East 3":l==15?"au>Australia":l==16?"swe>Sweden":l==17?"ca>Canada West":l==18?"fin>Finland":l==19?"nl>Netherlands 2":"us>Unknown")+"</td>");
d.write("<td>"+a+"</td>");
d.write("<td class="+(m==0?"f>Free":"m>Members")+"</td>");
d.write("</tr>");
} e(85,0,0,"-","ny1",903,13);e(40,0,0,"-","ny11",905,13);e(38,0,0,"-","ny9",920,13);e(41,0,0,"-","ny12",930,13);e(87,0,0,"-","ny4",936,13);e(90,0,0,"-","ny7",963,13);e(86,0,0,"-","ny2",983,13);e(33,0,0,"-","at1",781,7);e(101,0,0,"-","at7",822,7);e(34,0,0,"-","at2",825,7);e(35,0,0,"-","at3",829,7);e(102,0,0,"Falador Party Room","at8",885,7);e(57,0,0,"-","ch3",1197,11);e(55,0,0,"-","ch1",1199,11);e(74,0,0,"-","sl3",713,9);e(43,0,0,"-","sl11",716,9);e(75,0,0,"-","sl4",724,9);e(3,0,2,"Trade - F2P","sl1",1996,9);e(93,0,0,"-","mi1",672,14);e(96,0,0,"-","mi4",691,14);e(94,0,0,"-","mi2",692,14);e(95,0,0,"-","mi3",717,14);e(30,0,0,"-","po7",849,1);e(4,0,0,"Trade - F2P","po4",1959,1);e(5,0,0,"Trade - F2P","po5",1967,1);e(47,0,0,"-","above5",638,2);e(8,0,0,"-","above3",671,2);e(7,0,0,"-","above2",766,2);e(29,0,0,"-","ul6",1610,0);e(32,0,0,"-","ul1",1613,0);e(1,0,2,"Trade - F2P","ul7",2000,0);e(14,0,0,"-","nl4",624,4);e(19,0,0,"-","nl7",649,4);e(21,0,0,"-","nl11",654,4);e(13,0,0,"-","nl3",676,4);e(20,0,0,"-","nl8",717,4);e(62,0,0,"-","se2",636,12);e(61,0,0,"-","se1",640,12);e(63,0,0,"-","se3",641,12);e(113,0,0,"-","nav4",850,6);e(37,0,0,"-","nav3",865,6);e(72,0,0,"-","nav9",874,6);e(17,0,0,"PK - F2P","nav1",1402,6);e(127,0,0,"-","jlv3",643,17);e(126,0,0,"-","jlv2",646,17);e(128,0,0,"-","jlv4",647,17);e(125,0,0,"-","jlv9",650,17);e(80,0,0,"-","jolt1",1707,3);e(68,0,0,"PK - F2P","jolt11",1714,3);e(67,0,0,"-","jolt10",1716,3);e(11,0,0,"-","jolt8",1720,3);e(81,0,0,"-","jolt2",1757,3);e(106,0,0,"-","mn9",814,5);e(105,0,0,"Trade - F2P","mn8",819,5);e(15,0,0,"-","mn2",831,5);e(16,0,0,"Running - Air Runes","mn3",1288,5);e(52,0,0,"-","ams4",1019,10);e(50,0,0,"-","ams2",1037,10);e(51,0,0,"-","ams3",1057,10);e(141,0,0,"-","me1",626,19);e(142,0,0,"-","me2",651,19);e(10,0,0,"-","me5",652,19);e(25,0,0,"-","me6",665,19);e(118,0,0,"-","swe2",631,16);e(119,0,0,"-","swe3",633,16);e(117,0,0,"-","swe1",654,16);e(133,0,0,"-","hel1",612,18);e(134,0,0,"-","hel2",614,18);e(136,0,0,"-","hel4",629,18);e(135,0,0,"-","hel3",654,18);e(109,0,0,"-","au3",625,15);e(108,0,0,"-","au2",630,15);e(107,0,0,"-","au1",675,15);e(46,1,0,"-","ny14",886,13);e(88,1,0,"-","ny5",899,13);e(89,1,0,"-","ny6",899,13);e(45,1,0,"Burthorpe Games Room","ny13",917,13);e(91,1,0,"-","ny8",917,13);e(39,1,0,"-","ny10",931,13);e(103,1,0,"Falador Party Room","at9",763,7);e(104,1,0,"Trouble Brewing","at10",764,7);e(44,1,0,"-","at6",766,7);e(36,1,0,"Running - Nature Runes","at4",791,7);e(59,1,0,"-","ch5",954,11);e(58,1,0,"Blast Furnace","ch4",977,11);e(78,1,0,"-","sl7",678,9);e(76,1,0,"-","sl5",682,9);e(77,1,0,"Shades of Mort'ton","sl6",695,9);e(79,1,0,"Tzhaar Fight Pits","sl8",707,9);e(6,1,0,"Barbarian Assault","sl10",1980,9);e(98,1,0,"-","mi6",757,14);e(97,1,0,"-","mi5",771,14);e(99,1,0,"Running - Law Runes","mi7",776,14);e(42,1,0,"Role-Playing Server","po2",691,1);e(70,1,0,"-","po6",700,1);e(31,1,0,"House Parties","po8",934,1);e(48,1,0,"-","above6",690,2);e(9,1,0,"-","above4",1084,2);e(26,1,0,"Trade - Members","ul5",1136,0);e(100,1,0,"Group Questing","ul3",1144,0);e(2,1,2,"Trade - Members","ul8",2000,0);e(27,1,0,"Trade - Members","nl5",654,4);e(92,1,0,"-","nl9",662,4);e(56,1,0,"-","nl10",677,4);e(28,1,0,"-","nl6",682,4);e(22,1,0,"-","nl1",765,4);e(65,1,0,"-","se5",676,12);e(64,1,0,"-","se4",684,12);e(66,1,0,"Running - Law Runes","se6",889,12);e(114,1,0,"-","nav5",719,6);e(116,1,0,"Fishing Trawler","nav8",724,6);e(115,1,0,"Pest Control","nav6",727,6);e(18,1,0,"PK - Members","nav2",1970,6);e(132,1,0,"-","jlv8",671,17);e(131,1,0,"-","jlv7",672,17);e(129,1,0,"Duel Arena - Fun Duels","jlv5",677,17);e(130,1,0,"Duel Arena - Staking","jlv6",694,17);e(82,1,0,"Castle Wars","jolt3",1909,3);e(84,1,0,"-","jolt5",1913,3);e(83,1,0,"Duel Arena - Staking","jolt4",1933,3);e(69,1,0,"PK - Members","jolt12",1978,3);e(12,1,2,"Duel Arena - Fun Duels","jolt9",1999,3);e(23,1,0,"-","mn4",1659,5);e(71,1,0,"Barbarian Assault","mn7",1660,5);e(24,1,0,"Castle Wars","mn5",1674,5);e(53,1,0,"Pest Control","ams5",1929,10);e(54,1,0,"-","me10",1033,19);e(143,1,0,"-","me3",1055,19);e(144,1,2,"Pest Control","me4",2000,19);e(121,1,0,"-","swe5",707,16);e(124,1,0,"-","swe8",718,16);e(120,1,0,"-","swe4",827,16);e(137,1,0,"-","hel5",663,18);e(138,1,0,"Rat Pits","hel6",663,18);e(110,1,0,"-","au4",662,15);e(112,1,0,"-","au6",664,15);e(111,1,0,"-","au5",676,15);
</script>

Now I'm not saying this can't be done, it's just going to be as easy as 1-2-3. I'm guessing you're trying to pull all this stuff into a GUI for a bot you're working on. Could be pretty slick if you get it the way you want.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...