Cold Fusion Development
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Remember me

Go Back   Dev Articles Community ForumsProgrammingCold Fusion Development

Add This Thread To:   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
Unread Dev Articles Community Forums Sponsor:
Old March 5th, 2003, 06:07 PM
laridev laridev is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
Join Date: Dec 2002
Location: Miami
Posts: 29 laridev User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question image upload

I have a file where we are allowing images to be uploaded. I wrote the following code to get this accomplish....
<cfset Request.UploadDirectory = GetDirectoryFromPath(GetCurrentTemplatePath()) & "images/" />

<!--- here i Get the extension of the uploaded file. --->
<cfset Request.FileExt = ListLast(Request.SystemFileName, ".") />

<!--- Now I Upload the file. --->
<cffile action="upload"
destination="#Request.UploadDirectory#event_#Request.EventID#.# Request.FileExt#"
nameconflict="overwrite" />

<!--- I Update the event with the name of the file. --->
<cfquery datasource="#application.datasource#">
SET EventImage = 'event_#Request.EventID#.#Request.FileExt#'
WHERE EventID = #Request.EventID#
My problem is the following...we use webfileUtils to do our web uploads using asp. there is a certain way to upload it. How can I incorporate this into my code?
this is the asp code i got.
<beginning of asp code>
if action = "upload" then

pth = server.mappath("..") & "\images"
Response.Write "server.mappath = " & pth & "<br>"

Set ObjWebUpload = Server.CreateObject("WebFileUtils.WebUpload")
filename = ObjWebUpload.DoUpload(cstr(pth))
SQL = "insert into volunteer_pics(filename,caption) values ('"&filename&"','"&caption&"')"
set rst = cons.execute(SQL)
set rst = nothing

response.redirect "volunteer_opp_pics_admin.asp?action=main&validateuser=ok&validatepwd=ok"

End If
<end of asp code>
any help I can get on this will really help me.....

Reply With Quote

Viewing: Dev Articles Community ForumsProgrammingCold Fusion Development > image upload

Developer Shed Advertisers and Affiliates

Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 

Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.

© 2003-2019 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap