By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,963 Members | 1,834 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,963 IT Pros & Developers. It's quick & easy.

HTTP/URL Question

P: n/a
Is there a Filesystem or cURL function that will allow me to request a
url and send a specific string in the message or body of the request?

Also is there a way to display the web page once its in a handle?

Thanks for any answers!

May 18 '07 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On May 18, 6:02 am, cozofdeath <m...@hotmail.comwrote:
Is there a Filesystem or cURL function that will allow me to request a
url and send a specific string in the message or body of the request?

Also is there a way to display the web page once its in a handle?

Thanks for any answers!

Hi,
I have made this code and have tried it its running fine and I think
this will resolve your query..

<?php

$ch = curl_init("http://www.zimaudio.com/");
$fp = fopen("curl/example_homepage.txt", "w");

curl_setopt($ch, CURLOPT_FILE, $fp);
curl_setopt($ch, CURLOPT_HEADER, 0);

curl_exec($ch);
curl_close($ch);
fclose($fp);

$source = "curl/example_homepage.txt";
$html = file($source);
for( $i=0; $i<count($html); $i++ )
{
print $html[$i];
}
?>

Thanks,
Rahul S

May 18 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.