嵌入一个网页的代码

啊哈!找到了一个可以嵌入其它网页的代码,可以非常容易的显示其它站点的情况:

 <?php
$curl_handle = curl_init ();


curl_setopt ( $curl_handle , CURLOPT_URL , 'http://www.google.com' );


curl_setopt ( $curl_handle , CURLOPT_CONNECTTIMEOUT , 2 );

curl_setopt ( $curl_handle , CURLOPT_RETURNTRANSFER , 1 );
$buffer = curl_exec ( $curl_handle );

//This Keeps everything running smoothly
curl_close ( $curl_handle );

// Change the message bellow as you wish, please keep in mind you must have your message within the " " Quotes.
if (empty( $buffer ))
{
print "Sorry, It seems our weather resources are currently unavailable, please check back later." ;
}
else
{
print $buffer ;
}
?>