Closed Thread Icon

Topic awaiting preservation: get data from external site (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=8062" title="Pages that link to Topic awaiting preservation: get data from external site (Page 1 of 1)" rel="nofollow" >Topic awaiting preservation: get data from external site <span class="small">(Page 1 of 1)</span>\

 
qaddamage
Obsessive-Compulsive (I) Inmate

From: Kitzingen, Germany
Insane since: Feb 2002

posted posted 02-02-2002 10:45

I need to extract info from this game site for my personal site: http://my.uo.com/cgi-bin/guilds.pl?g=f68cc067f7061ebe:4
how do I incorporate the list of guild members into a jump menu form on MY site, so that I don't have to redo the menu manually, ie: I want my site to automatically extract the list from their site and create my own jump menu from the data.

Pugzly
Paranoid (IV) Inmate

From: 127.0.0.1
Insane since: Apr 2000

posted posted 02-02-2002 17:08

I wonder if you could some sort of web fetching for that. Check out hotscripts for some possible ideas.



[This message has been edited by Pugzly (edited 02-02-2002).]

Dracusis
Maniac (V) Inmate

From: Brisbane, Australia
Insane since: Apr 2001

posted posted 02-03-2002 00:17

You could use PHP to read the whole page into a variabul. Then regex the hell out of it untill you have what you need.

Just an Idea.

Bugimus
Maniac (V) Mad Scientist

From: New California
Insane since: Mar 2000

posted posted 02-03-2002 04:23

"regex the hell out of it"... Ha ha ha! I kind of like the sound of that.

mr.maX
Maniac (V) Mad Scientist

From: Belgrade, Serbia
Insane since: Sep 2000

posted posted 02-03-2002 08:19

Regular expressions are web coders best friend, heh he heeeee...


qaddamage
Obsessive-Compulsive (I) Inmate

From: Kitzingen, Germany
Insane since: Feb 2002

posted posted 02-03-2002 09:27

nice to see you all agree....so it's PHP (a script?), then standard HTML to strip it down? I'm only a hair beyond doing cheezy auto-build sites from hosting companies, so there may be more questions to follow.....

lallous
Paranoid (IV) Inmate

From: Lebanon
Insane since: May 2001

posted posted 02-04-2002 14:42

qaddamage,

here's the PHP code:

code:
$mem = join('', file('http://my.uo.com/cgi-bin/guilds.pl?g=f68cc067f7061ebe:4'));

$re= '<a href="http:\/\/my\.uo\.com\/cgi-bin\/my_chars\.pl[^"]+">([^<]+)<\/a>, ([^<]+)<br>';
if (preg_match_all("/$re/is", $mem, $members))
{
echo "$members[1][$i]-$members[2][$i]\n";
}



enjoy,

qaddamage
Obsessive-Compulsive (I) Inmate

From: Kitzingen, Germany
Insane since: Feb 2002

posted posted 02-04-2002 21:49

that's outstanding! I wouldn't have been able to pick that one apart on my own, thanks for taking the time to analyze the code on that site to figure out what I needed

« BackwardsOnwards »

Show Forum Drop Down Menu