You are here: Re: How to access remote files with php? « PHP « IT news, forums, messages
Re: How to access remote files with php?

Posted by Jason Barnett on 01/19/05 16:28

Sephiroth wrote:
> Hi all,
>
> How to access remote files with php?
> For ex:
> $sFile = "http://www.php.net/123.txt";
> if (file_exists($sFile)) {
> $hFile = fopen($sFile);
> ...
> fclose($hFile);
> }
>
>
> Regards,
> Sephiroth

You can use the file functions with URLs so long as you have
allow_url_fopen set to TRUE in your php.ini.

--
Teach a person to fish...

Ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html
PHP Manual: http://www.php.net/manual/en/index.php
php-general archives: http://marc.theaimsgroup.com/?l=php-general&w=2

 

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

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