Quantcast
Channel: Adobe Community : Popular Discussions - ColdFusion
Viewing all articles
Browse latest Browse all 14291

cfdirectory showing folders but not files CF11

$
0
0

I'm using the cfdirectory example code right of Adobe's site yet in CF11 I can only get it to show the folders in the directory and not any of the files.  Is it possibly a security setting in CF11?

 

The code is pretty basic:

 

<cfdirectory directory="D:/IIS" name="dirQuery" action="LIST">

 

<!--- Get an array of directory names. --->

<cfset dirsArray=arraynew(1)>

<cfset i=1>

<cfloop query="dirQuery">

<cfif dirQuery.type IS "dir">

    <cfset dirsArray[i]=dirQuery.name>

    <cfset i = i + 1>

</cfif>

</cfloop>

<cfdump var="#dirsArray#">

<br>

<!--- Get all directory information in a query of queries.--->

<cfquery dbtype="query" name="dirsOnly">

SELECT * FROM dirQuery

WHERE TYPE='Dir'

</cfquery>

<cfdump var="#dirsOnly#"

 

 

Thanks!

 

Gary


Viewing all articles
Browse latest Browse all 14291

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>