> writes file in php ~ Online tutorial

writes file in php

writes file in php



In PHP we are using fwrite() function to retrieve data in file.we are using fwrite() function that will return how many character will placed in the file only it is display.



html>


<body>
<?php
$content="hello world";
$f=fopen('today.txt','w');
// today.txt must in read.php location
$fh=fwrite($f,$content);
// it is no of character in content
echo $fh;
fclose($f);
?>
</body>
</html>

Output:





Please Give Us Your 1 Minute In Sharing This Post!
Please Give Us Your 1 Minute In Sharing This Post!
SOCIALIZE IT →
FOLLOW US →
SHARE IT →
Powered By: BloggerYard.Com

0 comments: