[eluser]myerman[/eluser]
So I have a section of our web site in which I display a list of PDFs (basically, PDF'd versions of articles I've written in the past). I was using directory_map() to just read off all the names of the files in a single directory.
This morning, I got the bright idea to organize those PDFs into subfolders and then use directory_map() to also capture the names of the directories. The documentation says that subdirectory names are captured. NOT.
here's the code in my controller:
Code:
$data['links'] = directory_map('./downloads/samples/');
Here's what I get instead....shouldn't the names of the subdirs be the keys?
Code:
Array
(
[0] => Array
(
[0] => oasis_of_culture(zoom).pdf
)
[1] => Array
(
[0] => hbm_best_use_of_technology.pdf
[1] => hbm_telecommute.pdf
[2] => basic_web_presence.pdf
[3] => Grow and Diversify your Business Online.pdf
[4] => hbm_equipment_startup.pdf
[5] => HBM_grow_your_business_online.pdf
)
[2] => Array
(
[0] => Information architecture concepts.pdf
[1] => Software_Development_the_Agile_Way.pdf
[2] => Planning for Domino on iSeries.pdf
[3] => Grid watch_ The importance of being stateful.pdf
)
)