Date: Tue, 13 Nov 2001 09:49:46 -0500
To: ColdFusion User Group
From: phumes1 <[EMAIL PROTECTED]>
Subject: Re: Using <cfheader and <cfcontent to open file in UltraEdit


Hi,

I'm using <cfheader and <cfcontent to open a file in Ultraedit on my PC
(client) from a link on the webserver.

Opening the file is working great except for one thing. I want the proper
path of the directory/filename to appear in my editor.
RIght now I get the following path

[D:\Documents and Settins\user.name\Local Settings\Temporary Internet 
Files\Content.IE5\SD6ZC1QR\filename[1].dat]

How can I get it to read "[D:\directory\subdirectory\filename.dat]"


Here is my code:

<cfset FileName = ListLast(url.filename, "\")>
<cfset DirPath = Left(url.filename, Evaluate(Len(url.filename) - 
len(FileName) - 1))>

<cfoutput>
<cfheader name="Content-Disposition" value="inline; filename=#FileName#">
<cfcontent type="application/dat" 
file="d:/directory/subdirectory/#FileName#" deletefile="No">
</cfoutput>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to