how to export excel file in same server


Posted on 16th Feb 2014 07:03 pm by admin

My first post - php newbie, so appreciate your support.

I'm currently using headers to save web page as excel file.

Did you know?Explore Trending and Topic pages for more stories like this.
$filename="sms.xls";
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Cache-Control: public");
header("Content-Description: File Transfer");
header("Content-Type: application/vnd.ms-excel");
$header="Content-Disposition: attachment; filename=".$filename.";";
header($header);
header("Content-Transfer-Encoding: binary");
@readfile($file);

I want to be able to save a copy to the server not to opening dialog save?
Not sure what I need to change or add to achieve this?

Have looked around and tried searching on here? - can't see the search threads feature if there is one?

Many thanks
No comments posted yet

Your Answer:

Login to answer
257 Like 51 Dislike
Previous forums Next forums
Other forums

upload only text files
hi guys i want to upload only text like like (pdf,note pad and ofiice files) so can any one please t

http to https
Hi,

Is there any specific method/condition to move an http:// page to https:// ?

Date/Time and Checkbox
Hi Everyone,

I am trying to figure out how to insert the current date and tim

How to secure my login data to my database?
Hi there,

It may be a stupid question but I don't know how to secure my login data to my data

Help Import Animoto and Youtube
CAn someone help me urgently want to allow users on my website to import youtube/revver/dailymotion

Conditions of info record - Error
When i created GR (901) and PO create automatic my PBXX is obtain the net price of info record but

help removing unwanted graphic
How do I remove the small elongated rectangular shape between the "Latest post" and "

SQL Injection
In my attempts to protect my database from mySQL injection I have created another problem for myself

Delete all files in folder except with certain name
I have a script that I want to delete all files in a folder (taken from a database) except for one n

form variables from database help.
Hi all,

I would like to have a form that gives you options based on the results of an mysql q

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash