Trying to go back and update my web app to close the door behind some things. Trying to delete images from the server when someone deletes an item from the database.

(I'm using CF 5 & SQL DB)

Here's some code:.

<cfquery name="deleteProduct">
DELETE FROM products
WHERE productid = #URL.productid#
</cfquery>

<cfquery name="deleteImage">
SELECT *
FROM products
WHERE productid = #URL.productid#
</cfquery>

<!--- Delete Images --->
<cfoutput query="deleteImage">
<cffile action="" file="c:\inetpub\lanescollectibles\images\400\#lanesid#.jpg">
<cffile action="" file="c:\inetpub\lanescollectibles\images\200\#lanesid#.jpg">
<cffile action="" file="c:\inetpub\lanescollectibles\images\85\#lanesid#.jpg">
</cfoutput>

Any help greatly appreciated!

TIA,

Donna
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to