Hi all,
I and my collegue are trying to use what I believe are commonly
reffered to as `search engine friendly URLs' (replacing the ?, & and =
symbols in a query string with the forward slash character / ) in order to facilitate
the
download of a specified file using CFCONTENT. That is, the file(s) may
only be downloaded by those people who have the appropriate authorisation
- by logging into the site - to download the file.
I proposed to do this by using search engine friendly URLs to provide a file
identifier to a
cold fusion template (fusebox, but that's not important) which would use
CFCONTENT to return the file to the browser (and delete it promptly
afterwards) while having the browser think it is downloading a corectly
named file (not template.cfm but blahblah.pdf (.mdb, .zip, .xxx).
eg, instead of a URL of
template.cfm?FileID=123
and the user then being prompted by the browser to save (or open...)
the file "template.cfm?FileID=123" which isn't what I intended, I use a
URL of
template.cfm/FileID/123/bogusVar/blahblah.pdf
and the user would be prompted to save the file "blahblah.pdf" which is
correct.
Anyway I was sure this should work as I have seen it done in other places
I'm sure, and I'm certain that I at least had it working at one stage in
another site some time ago. Problem is, it doesn't, as soon as I put an
filename with an extention other than .cfm the web server (IIS) complans
that it cant find the file (it thinks there really is a file
template.cfm/FileID/123/bogusVar/blahblah.pdf), if however I remove the
filename from end of the URL (so template.cfm/FileID/123), or infact even
just change the extention of the filename to .cfm
(template.cfm/FileID/123/bogusVar/blahblah.cfm) the server understands
that it should send the request to the CF server to process template.cfm.
Any ideas why these types of URL's just won't work for me anybody ? Is
there another solution to making the users browser think it is requesting
a different file than it really is (thinks it requests blahblah.pdf when
it really requests template.cfm) ?
---
James Sleeman
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.