Following on from Simple Text Storage With PHP, when using flat-file storage you also need to pull the data from the text files. This tutorial will explain how to extract a piece of information from a text file and display it.
When I first started learning PHP I didn’t want to overload myself with learning about SQL as well, so I used text files for storage instead (also known as flat-file databases).
I am going to show you how to write information to a text file using PHP. You don’t have to have any PHP knowledge at all in order to follow this tutorial.
This tutorial will allow you to have a basic file upload interface with a PHP backend. This tutorial is only for educational purposes and the final PHP file upload script is not robust nor secure enough for a commercial solution.
In your PHP scripts at some stage you may wish or need to completely change the directory in which to look in - for examples the directory to look for files to include. This tutorial shows you how to change dir for file inclusion.