> Still a little confused as to how to accomplish this. > > This, as a test, works fine: > > <cfmail to="[EMAIL PROTECTED]" from=#name# subject="file test" > type="HTML" > mimeattach="e:\inetpub\hostroot\aaintl.com\MailFiles\MyFile.txt"> > > > However, the problem I'm now having, is when I try to replace > "MyFile.txt" with the name of the file from the form field > #MyFile#, it's pulling the ENTIRE entry in the form field... > > In other words...if I choose "D:\MyDocs\TextFiles\MyFile.txt" > to upload to the server - that entire path gets appended to the > path in the mimeattach statement in the CFMAIL tag: > > mimeattach="e:\inetpub\hostroot\aaintl.com\MailFiles\D:\MyDocs\Text > Files\MyFile.txt" > > So, somehow I've got to eliminate the path part that's coming > from the form and just get the file name by itself. That's right. As Mr. Crawford indicated, you'll want to use the name of the actual file on the server, not the name of the file that was uploaded. These will be different, since you specified "overwrite" in your CFFILE's NAMECONFLICT attribute. So, you may upload "MyFile.txt", but it will be saved on the server as "AC3.tmp" or something like that. You can reference this value by using the variable File.ServerFile in your MIMEATTACH attribute: <cfmail ... mimeattach="e:\inetpub\hostroot\aaintl.com\MailFiles\#File.ServerFile#"> Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ voice: (202) 797-5496 fax: (202) 797-5444 ------------------------------------------------------------------------------ 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.

