Before I go digging around and start trying to code a solution, I'd like
to know if what I'm trying to do is even possible.
I'm trying to automate the downloading of data from a site.
First, I have to go to a login page, enter my username and password,
then I'm taken to the download page.
Thanks for the feedback, Dave.
At least I know it's possible.
Rick
Dave Watts wrote:
Before I go digging around and start trying to code a solution, I'd like
to know if what I'm trying to do is even possible.
I'm trying to automate the downloading of data from a site.
First, I have to go
I'll save you a google search and give you the links to Ben Nadel, who's
already done all the work:
http://www.bennadel.com/blog/725-maintaining-sessions-across-multiple-coldfusion-cfhttp-requests.htm
http://www.bennadel.com/projects/cfhttp-session.htm
mxAjax / CFAjax docs and other useful
Thanks, James! I'm on it! :o)
Rick
James Holmes wrote:
I'll save you a google search and give you the links to Ben Nadel, who's
already done all the work:
http://www.bennadel.com/blog/725-maintaining-sessions-across-multiple-coldfusion-cfhttp-requests.htm
We use a real simple piece of code to trigger a file download.
We save this in a page called download.cfm
cfset filePath = C:\foo
cfheader name=Content-Disposition value=attachment;
filename=#getFileFromPath(filePath)#
cfcontent file=#filePath# type=application/x-unknown
Then we call it with a
Hi, all...
Before I go digging around and start trying to code a solution, I'd like
to know if what I'm trying to do is even possible.
I'm trying to automate the downloading of data from a site.
First, I have to go to a login page, enter my username and password,
then I'm taken to the download
From my experience you can't really control the save as/open dialog from
your end. That is generally handled by the browser and OS as they see
fit. File formats that can be opened right there in the browser
(images, html, text) tend to just open up in that window when you click
the link. Most
Actually you can control the way a link opens if your trying to push a file
when a user clicks a link. If the link is to a coldfusion page that then
grabs the file sets header info and content type.
I do this for mp3 files.
download.cfm
--start file--
cfparam name=url.songname default=
cfif
If you want to force the Save File dialog appear you can use
application/unknown as the content type for cfcontent. At least that
behaves on windows boxes.
EX: cfcontent type=application/unknowncfoutput#yourdata#/cfoutput
On Thu, Oct 16, 2008 at 3:35 PM, Wil Genovese [EMAIL PROTECTED] wrote:
Ahh, good tip on the cfheader name=Content-Disposition
value=Attachment; filename=#clipname# bit.
I have never used that before. Of course, that also means you burn a
thread to server the download. I wonder if there is an easy way to link
directly to the file, but force apache or IIS to provide
You could have an .htaccess file in your downloads directory that adds
the content type to do this, for files retrieved from that directory.
-Ryan
[EMAIL PROTECTED] wrote:
Ahh, good tip on the cfheader name=Content-Disposition
value=Attachment; filename=#clipname# bit.
I have never used that
Thanks for the feedback, Wil...
I'm not sure however, that we're talking about the same thing.
I'm trying to automate going to a data vendor's site, logging in to their
web page, then triggering a link on the next page to cause a download
of a file to start... I'm the one doing the downloading
oh well that's different.
Hmmm. CFHTTP? post login info followed by another CFHTTP to get
the file? Not sure how I would do that. assuming the login is session
based cfhttp may not work since they would need to set a session cookie.
Not sure. Now I will be thinking about this instead
13 matches
Mail list logo