| Subject: | Re: Listing Files and Directories |
|---|---|
| From: | Ian Skinner <iskinner@xxxxxxxxxxx> |
| Date: | Wed, 30 Jul 2008 09:59:48 -0700 |
| Newsgroups: | macromedia.coldfusion.cfml_general_discussion |
Vidikron wrote: On our internal web page we have some links to various areas like Office Forms, Safety, etc... The supervisors that maintain these documents have access to shares that allow them add, remove, and update the files as needed. Since the content in each changes fairly often we're currently using CFDIRECTORY with the LIST action to display the contents to the users on the web page.Some of the areas now contain quite a few documents and the supervisors would like to be able to group their documents in subdirectories. I know I can I can use RECURSE="yes" to have the web page list the contents of these folders, but the supervisors would like the end users to see the subdirectories as well so things are less confusing and cluttered on both ends. So is there any way in CF to set up these pages so that subdirectories can can be navigated and the documents selected? If possible, I'd like something that can handle this dynamically so that I don't have to constantly change the code every time a supervisor decides to add/remove a directory. We're currently running CF8 Standard.Thanks! Pretty much what you got should do it. The simplest change would be to output entire directory structure on your current page, just nesting the files and directories. I would just create a looping output that uses the fields of the record set to output the directories and the files with-in them probably as a nested set of <ul> unordered lists. If you want to break up this user interface into distinct units which only list the contents of a current directory then just do the output as you have it without using recursion. But make the sub-directory listings links that when clicked repopulate the current page listing the contents of the selected directory. Neither should take a great deal of rework to your current interface. |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Listing Files and Directories, Vidikron |
|---|---|
| Next by Date: | Re: Listing Files and Directories, Vidikron |
| Previous by Thread: | Listing Files and Directories, Vidikron |
| Next by Thread: | Re: Listing Files and Directories, Vidikron |
| Indexes: | [Date] [Thread] [Top] [All Lists] |