PHP tutorials,a way to getting some thing new in web

Followers

Powered by Blogger.

Tuesday 5 August 2014

How To Read Text Files using PHP

No comments :
I have posted tutorials for creating and posting of data.But here is good code and easy way in php to read text files which is stored in folder.In last post, I have posted code for making text file and directory.We will read data of same file.As assumed in code,files are same but contents in text file may be different.



Check out code for the same as follow:

<?php
$newdir='RuchiS';
echo  readfile($newdir.'/' ."newfile.txt");
?>


The above codee show one line which is reason for execution or say function names readfile.
 readfile is function in php which helps to read text file. 


No comments :

Post a Comment