PHP File Open/Read/Close
snippet in php

PHP File Open/Read/Close

user256

$myfile= fopen("welcom.txt","w");
echo fwrite($myfile, filesize("welcom.txt"));
fclose($myfile);

open file in php

user6980


 <?php
$myfile = fopen("webdictionary.txt", "r") or die("Unable to open file!");
echo fread($myfile,filesize("webdictionary.txt"));

 fclose($myfile);
?>
 

PHP File Open/Read/Close

user1674

require_once "php2/include.php";
echo $varriable;

echo fread($myfile,filesize("webdictionary.txt"));

user452

<?php
    $myfile = fopen ("webdictionary.txt" , "r") or die ("Unable to open file!");
    echo fread ("$myfile", filesize ("webdictionary.txt"));
    fclose ($myfile);