to your server. That's a hacker's paradise. The only way I can think
to do it would be to have some kind of an editor built into your page
that creates the files or allow a user to upload files from their
computer and save it into the database that way. You can't let them
just edit the file in the browser and File->Save though. That's a local
operation, not a server thing.
John
-----Original Message-----
From: cf coder [mailto:[EMAIL PROTECTED]
Sent: Wednesday, April 14, 2004 5:49 AM
To: CF-Talk
Subject: how to save a document/spreadsheet/pdf into a database table
when it is open?
Hello Everybody, I'm hoping somebody will provide me with some help. I
have this section on my site where a user can view his or her
attachments. The attachments that can be a word documents, a
spreadsheets or a pdf are stored in a database table as binary objects.
I've done the bit to allow the user to view the document. I did this
with the help of the cfx_getImage tag, which opens the document inside a
browser window.
---------------------
<CFX_GETIMAGE
DATASOURCE="db"
USER="dbUserName"
PASSWORD="dbPassword"
SQL="select filename FROM dbo.Attachment WHERE id = '#url.id#'"
OUTPUT="E:\inetpub\wwwroot\tempDocumentsFolder\#getAttachmentDetails.Fil
eName#">
<CFHEADER NAME="Content-Type"
VALUE="application/msexcel">
<CFHEADER NAME="Content-Disposition" VALUE="inline;
filename=testDoc.xls">
<CFCONTENT TYPE="application/msexcel"
FILE="E:\inetpub\wwwroot\testDocs.xls"
deletefile="Yes">
----------------------
I want to now add the code that saves back the
contents of the document in the database table when
the user clicks on File->Save option from the menu or
ctrl-s from the keyboard.
Is this possible, if so can someone please show me how
to do this?
Best regards,
cfcoder
__________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online by April 15th
http://taxes.yahoo.com/filing.html
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

