Listing files in a directory with Rails

Hits: 5195

In a recent application I am building I needed to pull file names and directory names from a local directory. I searched all over the net for this and found nothing. After reviewing a few of rails built in functions I came across Dir.glob(). If you feed this method a path to a directory it will then come back with an array of the names and directories listed

Rating Graph

Rating Graph

Resource Details:

Price :
Date Added :
Tue Apr 1, 2008
Author :
Other Listing by User
Rate :
Rate Scripts4.0(out of 5)
Vote :
1 Votes
Vote Now :

User Reviews