RE: CFDIRECTORY question

2004-12-02 Thread Robert Orlini
With your suggestion and a few tweaks it does what I want. Thanks Mike! Robert O. -Original Message- From: Dawson, Michael [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 01, 2004 4:34 PM To: CF-Talk Subject: RE: CFDIRECTORY question Why not just use CFDIRECTORY on each page

RE: CFDIRECTORY question

2004-12-01 Thread Dawson, Michael
Why not just use CFDIRECTORY on each page request? This will ensure that you have the most up-to-date list of directories. What is the point of adding these to the database which could quickly become outdated? If you still need to do this, I would query the database, then run CFDIRECTORY.

RE: CFDIRECTORY question

2004-12-01 Thread Dawson, Michael
One other option is to run CFDIRECTORY, clear the table and reload it with the CFDIRECTORY results. If you were to do this, I would use a named CFLOCK around the code to ensure that no person hits an empty table while you are updating it. M!ke -Original Message- From: Robert Orlini

RE: CFDIRECTORY question

2004-12-01 Thread Andrew Scott
There are a number of ways to do this, but the easiest and not sure if it is the quickest way. Is to loop through and do a query to see if that directory is listed in the database if it isn't then do an insert into the database. Regards, Andrew Scott -Original Message- From: Robert

RE: CFDIRECTORY question

2004-12-01 Thread Dawson, Michael
, but it will reduce the number of data base interactions by two. Six of one, 1/2-dozen of the other... -Original Message- From: Andrew Scott [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 01, 2004 7:49 PM To: CF-Talk Subject: RE: CFDIRECTORY question There are a number of ways

RE: CFDirectory Question

2002-09-09 Thread Tony Weeg
keep your image references in a table in a database, so that when a product is entered, so is the path to/or a boolean field denoting an image exists for this product, and same when you edit/update/delete the product, you can also make the call to the db to remove the image/image reference. this

RE: CFDirectory Question

2002-09-09 Thread Adrian Lynch
use cfdirectory to get a list of files in the directory, loop through it to find the right one, or rather if it exists, if it doesn't, display your default gif/jpg A bit simplified maybe, but that's the gist(?) of it Ade -Original Message- From: Larry Juncker [mailto:[EMAIL PROTECTED]]

Re: CFDirectory Question

2002-09-09 Thread Tim Painter
FileExists(): cfif FileExists(images/#sku#.gif) img src=images/#sku#.gif cfelseif FileExists(images/#sku#.jpg) img src=images/#sku#.gif /cfif Though I'd prefer Tonys method, so you don't have to do a lot of file checking. We use it a lot on a app here and haven't run into any

RE: CFDirectory Question

2002-09-09 Thread Pascal Peters
Use the function FileExists(ExpandPath(images/ sku .gif)) -Original Message- From: Larry Juncker [mailto:[EMAIL PROTECTED]] Sent: maandag 9 september 2002 15:10 To: CF-Talk Subject: CFDirectory Question I have a shopping cart that I have created and the images can be either gif or

Re: CFDirectory Question

2002-09-09 Thread S . Isaac Dealey
I'd also recommend storing the file extension in the products table in your db, however, if you need to get it from file system, the simplest way is probably this: cfdirectory action=list name=rsprodimg filter=#sku#.* directory=#ExpandPath('images')# cfif len(rsprodimg.name[1])img

Re: CFDirectory Question

2002-09-09 Thread Joe Eugene
cfdirectory action = list directory = directory name = queryName filter = *.jpg should do it. // whatever u want to filer.. Joe - Original Message - From: Larry Juncker [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Monday, September 09, 2002 9:10 AM Subject: CFDirectory

Re: CFDirectory Question

2002-09-09 Thread Larry Juncker
[EMAIL PROTECTED] Sent: Monday, September 09, 2002 8:23 AM Subject: Re: CFDirectory Question FileExists(): cfif FileExists(images/#sku#.gif) img src=images/#sku#.gif cfelseif FileExists(images/#sku#.jpg) img src=images/#sku#.gif /cfif Though I'd prefer Tonys method, so you don't

Re: CFDIRECTORY question

2001-03-27 Thread W Luke
Jay, There's a tag cfx_wait in the gallery that might help you. After the deleting-images query, you might want to execute this tag to wait x seconds before processing the next line. Will -- [EMAIL PROTECTED] -=- www.lukrative.com Local-Advertising -=- www.localbounty.com - Original

Re: CFDIRECTORY Question -- Simple I Hope !

2001-03-24 Thread Gerry Pauline
Randy: Thanks for the note. As usual, after sending my note to the list, when I re-read the manual for the size parameter, "size of directory entry", I realized I had misinterpreted the section. -Gerry "Adkins, Randy" wrote: A Directory will have the filesize of ZERO. It will not give you

RE: CFDIRECTORY Question -- Simple I Hope !

2001-03-23 Thread Adkins, Randy
A Directory will have the filesize of ZERO. It will not give you the Total file size of all files located in that Directory. You will have to take each Directory then ReQuery that Directory to get the total. You make check the Dev Exchange to see if there is a Tag already that does this for

Re: CFDIRECTORY question

2000-09-06 Thread David Shadovitz
You can trim the extension via #ListFirst(qDirectory.Name,".")# (assuming there's only one period per file name). What's wrong with a simple CFQUERYinsert/CFQUERY? -David On Tue, 5 Sep 2000 Jacob McKee [EMAIL PROTECTED] writes: Please help! I need to know how to read all the files in a