Hello folks, In need of some feedback,direction, examples etc, for a little routine I'm playing with to learn a little more about using cf and more specifically, cfdirectory. Basically passing a form variable into this to create my base directory using the name passed from the form.....simple enough. I'm wondering if there's any way to roll up all 3 directory actions into a single tag or loop of some kind?? While this works fine, I'm just looking to condense if possible....lazy in my old age I guess ;-) <cfset BaseDir = "D:\wwwsites\mysite\#form.clientDir#"> <cfset ImageDir = "D:\wwwsites\mysite\#form.clientDir#\images"> <cfset CSSDir ="D:\wwwsites\mysite\#form.clientDir#\css">
<cfdirectory action="create" newdirectory="testClient" directory="#BaseDir#"> <cfdirectory action="create" newdirectory="images" directory="#ImageDir#"> <cfdirectory action="create" newdirectory="css" directory="#CSSDir#"> <cfdirectory action="list" directory="#BaseDir#" name="myDirList"> <cffile action="write" file="#BaseDir#\index.cfm" output="Directories created successfully."> <cffile action="read" file="#BaseDir#\index.cfm" variable="myVariable"> <cfoutput> #HTMLCodeFormat(myVariable)# </cfoutput> TIA .... Old Fart ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting, up-to-date ColdFusion information by your peers, delivered to your door four times a year. http://www.fusionauthority.com/quarterly Archive: http://www.houseoffusion.com/groups/CF-Newbie/message.cfm/messageid:2233 Subscription: http://www.houseoffusion.com/groups/CF-Newbie/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15
