Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

<cfdirectory> reading file names

Status
Not open for further replies.

newbby

Programmer
Mar 16, 2004
36
US
All,
I have a select box which I am successfull in capturing all the directory(folder) names using <cfdirectory>. How can I build another select box which will populate with all the file names for each folder selected from previous select. Thanks
 
You'll have to issue another CFDIRECTORY for each folder in the root or requested start folder.

Now, for the tricky part: If you want the second select box to populate on the client side based on what was selected in the first box, take a good look at the source code for the custom tag CF_TwoSelectsRelated. I'm not sure if you can use this tag "out of the box" given your requirements.

If you can stand another round-trip to the server, just give the selected folder name to CFDIRECTORY and populate the second select box with the results.

HTH,

Phil Hegedusich
Senior Web Developer
IIMAK
-----------
In one hundred years, none of this will matter. Keep a healthy perspective!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top