This is a discussion on How to use file() function with an "HTTPS:\\www.example.com" within the PHP General forums, part of the PHP Programming Forums category; How to use file() function with an "HTTPS:\\www.example.com" <?php $lines = file ('https://www.example....
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
How to use file() function with an "HTTPS:\\www.example.com"
<?php $lines = file ('https://www.example.com/'); foreach ($lines as $line_num => $line) { echo "Line #<b>{$line_num}</b> : " . htmlspecialchars($line) . "<br>\n"; } ?> Thanks a million! Rodrigo Nakahodo --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.518 / Virus Database: 316 - Release Date: 9/11/2003 |
|
|||
|
> How to use file() function with an "HTTPS:\\www.example.com"
> > <?php > > $lines = file ('https://www.example.com/'); > > foreach ($lines as $line_num => $line) { > echo "Line #<b>{$line_num}</b> : " . htmlspecialchars($line) > . "<br>\n"; > } My interpretation of the manual page (http://us3.php.net/manual/en/function.file.php) is as follows: 1.) you need fopen_wrappers enabled 2.) https is only available in versions >= 4.3.0 |
|
|||
|
Recompile php with built-in openssl support (--with-openssl) will do that.
[]'s Daniel Souza "Rodrigo Nakahodo" <rodrigo.nakahodo@dhweb.com.br> escreveu na mensagem news:CDEHLLEHEALJLBPKANBGGEOACAAA.rodrigo.nakahodo @dhweb.com.br... > How to use file() function with an "HTTPS:\\www.example.com" > > <?php > > $lines = file ('https://www.example.com/'); > > foreach ($lines as $line_num => $line) { > echo "Line #<b>{$line_num}</b> : " . htmlspecialchars($line) . "<br>\n"; > } > > ?> > > Thanks a million! > > Rodrigo Nakahodo > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.518 / Virus Database: 316 - Release Date: 9/11/2003 |