In all actuality I will be manipulating the information that is in that file.
I'm trying to build a log in script. The id's and passwords are stored in a
text file. I'm trying to read that text file so I can compare what the
user/viewer had typed in the id and password boxes. I'm so new to PHP
On Mon, 27 Jan 2003, Guru Geek wrote:
> Sorry, here is the code now ( I need a nap )
>
> $filename
> ="/usr/local/plesk/apache/vhosts/myserver.com/httpdocs/include/text.txt";
> $handle = fopen ($filename, "r");
> $contents = fread ($handle, filesize ($filename));
> fclose ($handle);
> echo $conte
Sorry, here is the code now ( I need a nap )
$filename
="/usr/local/plesk/apache/vhosts/myserver.com/httpdocs/include/text.txt";
$handle = fopen ($filename, "r");
$contents = fread ($handle, filesize ($filename));
fclose ($handle);
echo $contents;
exit;
Guru Geek wrote:
> Here's my code now:
>
Here's my code now:
$filename =
"/usr/local/plesk/apache/vhosts/myserver.com/httpdocs/include/text.txt";
$handle = fopen ($filename, "r");
$contents = fread ($handle, filesize ($filename));
fclose ($handle);
echo readfile($filename);
exit;
now it displays the contents of the text.txt file. I ori
On Mon, 27 Jan 2003, Guru Geek wrote:
> Hello,
>
> I'm a recent convert from CGI/Perl and so am still getting my feet wet
> in PHP.
>
> Here's my code:
> $filename = "http://www.myserver.com/include/sometext.txt";;
> $handle = fopen ($filename, "rb");
> $contents = fread ($handle, filesize ($fi
Hello,
The PHP manual page for filesize
(http://www.php.net/manual/en/function.filesize.php) mentions that it
will not work on remote files. fread will stop once n number of bytes
are read or EOF is received so you could set this to the maximum file
size (in bytes) that you want to download.
Jas
Hello,
I'm a recent convert from CGI/Perl and so am still getting my feet wet
in PHP.
Here's my code:
$filename = "http://www.myserver.com/include/sometext.txt";;
$handle = fopen ($filename, "rb");
$contents = fread ($handle, filesize ($filename));
fclose ($handle);
echo $contents;
exit;
The pro
7 matches
Mail list logo