You are here: Re: HTTP/URL Question « PHP Programming Language « IT news, forums, messages
Re: HTTP/URL Question

Posted by rahul sinha on 05/18/07 07:49

On May 18, 6:02 am, cozofdeath <m...@hotmail.com> wrote:
> 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

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация