Published in: PHP
URL: http://www.spoono.com/php/tutorials/tutorial.php?id=10
A simple script that lists all the items in the directory including folders and files and even makes a link out of them. Its an all purpose script which you can use to do other things.
//define the path as relative $path = "/home/yoursite/public_html/whatever"; //using the opendir function echo "Directory Listing of $path<br/>"; //running the while loop { //encode spaces // convert the + (this is one result from the function rawurlencode) in %20 } //closing the directory
You need to login to post a comment.
