How do i get PHP to grab infomation/text from another website??
(I want PHP to grab my teams score from caleague.com and post it on my teams website)
[HELP]php grabber
Moderator: General Moderators
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
- shiznatix
- DevNet Master
- Posts: 2745
- Joined: Tue Dec 28, 2004 5:57 pm
- Location: Tallinn, Estonia
- Contact:
many different ways. probably the easiest would be do just do
then you are going to have to use some regex to get that desired information out of $data. that is definatly going to be the hardest part. post what you are looking to get out of it (like maybe the html where the information is) then someone can help you write that regex.
edit: sigh, i am getting too slow.
Code: Select all
$data = file_get_contents('http://www.website_to_get.com');edit: sigh, i am getting too slow.
shiznatix wrote:many different ways. probably the easiest would be do just do
post what you are looking to get out of it (like maybe the html where the information is) then someone can help you write that regex.Code: Select all
$data = file_get_contents('http://www.website_to_get.com');
edit: sigh, i am getting too slow.
http://caleague.com/?page=teams&teamid=42842 = the website to get
Record <CHANGES> = data i want to get