Ali,

Thanks for that information, I was interested in the
application/octet-stream, couldn't remember that.

I figured that I would have to check the extension.  Just in case you
are using 4.0+, I converted your code over in case anyone was
interested.

Once again, thanks a lot.

Greg


<--- Begin Code --->

<CFSWITCH EXPRESSION="#ListLast(FileName,'.')#">
 <CFCASE VALUE="txt">
  <CFSET Type ="text/plain">
 </CFCASE>
 <CFCASE VALUE="htm,html,pl">
  <CFSET Type ="text/html">
 </CFCASE>
 <CFCASE VALUE="doc">
  <CFSET Type ="application/msword">
 </CFCASE>
 <CFCASE VALUE="xls">
  <CFSET Type ="application/msexcel">
 </CFCASE>
 <CFCASE VALUE="mdb">
  <CFSET Type ="application/msaccess">
 </CFCASE>
 <CFCASE VALUE="zip">
  <CFSET Type ="application/x-zip-compressed">
 </CFCASE>
 <CFCASE VALUE="pdf">
  <CFSET Type = "application/pdf">
 </CFCASE>
 <CFCASE VALUE="gif">
  <CFSET Type = "image/gif">
 </CFCASE>
 <CFCASE VALUE="jpg,jpeg">
  <CFSET Type = "image/jpeg">
 </CFCASE>
 <CFCASE VALUE="bmp">
  <CFSET Type = "x-MS-bmp">
 </CFCASE>
 <CFDEFAULTCASE>
  <CFSET Type="application/octet-stream">
 </CFDEFAULTCASE>
</CFSWITCH>

<!--- End Code --->


========================================================================
     This list server is Power by iMS
  'The Swiss Army Knife of Mail Servers'
   -------------------------------------
To leave this list please complete the form at 
http://www.CoolFusion.com/iMS.htm

List archives: http://www.mail-archive.com/infusion-email%40eoscape.com/
========================================================================

Reply via email to