• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 192
  • Last Modified:

rewrite php to coldfusion

I need to convert the following into coldfusion code.  Any ideas?
 * Export data, delivered in the POST, to excel.
 * @author S.Radovanovic
 * @version $Id$
header('ETag: etagforie7download'); //IE7 requires this header
header('Content-type: application/octet_stream');
header('Content-disposition: attachment; filename="rapportage.xls"');
//Add html tags, so that excel can interpret it
echo "<html>

Open in new window

1 Solution

<cfif structKeyExists(form, 'htmltable') >  
    <cfcontent type="application/msexcel">  
    <cfheader name="Content-Disposition" value="filename=excelFile.xls">  

Open in new window

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Easily Design & Build Your Next Website

Squarespace’s all-in-one platform gives you everything you need to express yourself creatively online, whether it is with a domain, website, or online store. Get started with your free trial today, and when ready, take 10% off your first purchase with offer code 'EXPERTS'.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now