/    Sign up×
Community /Pin to ProfileBookmark

Generation of excel file

Hi,

I need code for storing my output into an excel file. I need to store this file in the server.
We are using Spreadsheet_Excel_Writer from Pear package.

I could send it as attachment. But I need to store it in the server.

Code for sending as attachment:

header(“Content-type: application/vnd.ms-excel”);
header(“Content-Disposition: attachment; filename=$filename”);
header(“Expires: 0”);
header(“Cache-Control: must-revalidate, post-check=0,pre-check=0”);
header(“Pragma: public”);

If anybody has done it before, pls help.

Thanks,
Sadanandam.

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@pipetenOct 18.2006 — Heya,

You need to look into fopen, fwrite and maybe ob_* (ob_start, ob_flush) depending how your going to do it.
×

Success!

Help @sadanandam spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...