I am trying to export some info to excel, it's working perfectly fine however the html of the page is also being exported into excel.
Here's a basic example of what I am doing
In Excel I get
boom
<html>
<head></head>
<body></body>
</html>
How do I get it to not output the html also?
Thanks
Here's a basic example of what I am doing
Code:
<?php
Header("Content-Disposition: attachment; filename=export.csv");
print "boom";
?>
<html>
<head></head>
<body></body>
</html>
In Excel I get
boom
<html>
<head></head>
<body></body>
</html>
How do I get it to not output the html also?
Thanks