Jump to content


Photo

PHP getting other web pages.


  • Please log in to reply
3 replies to this topic

#1 ReVeR

ReVeR
  • Members
  • PipPipPip
  • Advanced Member
  • 42 posts

Posted 26 February 2006 - 03:02 AM

Hello.
I need to download another web page from my web site. How cna i do that?
say the web page is www.google.ca, how can i get the source code using php?
Thx

#2 Kris

Kris
  • Staff Alumni
  • Advanced Member
  • 2,755 posts
  • LocationThe Internet

Posted 26 February 2006 - 12:53 PM

fopen() - Check the manual for more info and related functions.

#3 hitman6003

hitman6003
  • Members
  • PipPipPip
  • Advanced Member
  • 1,807 posts

Posted 26 February 2006 - 01:40 PM

Why is everyone so interested in doing this the last few days?

In addition to fopen and fread, you can use file_get_contents (http://www.php.net/file_get_contents) and the cURL functions (http://www.php.net/curl).

#4 ReVeR

ReVeR
  • Members
  • PipPipPip
  • Advanced Member
  • 42 posts

Posted 26 February 2006 - 03:26 PM

many thanks, i will go check that out.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users