Home > Archive > PHP Language > May 2006 > Excel Documents
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Robert Bravery 2006-05-22, 3:59 am |
| HI all,
Newbie here. How can I display excel documents on my website, for our users
to view and or download, using php
Thanks
Robert
| |
| Michael Vilain 2006-05-22, 6:59 pm |
| In article <e4romg$9ee$1@ctb-nnrp2.saix.net>,
"Robert Bravery" <robert@db2k.co.za> wrote:
> HI all,
> Newbie here. How can I display excel documents on my website, for our users
> to view and or download, using php
>
> Thanks
> Robert
You can't display them like they appear in Excel unless you export them
as table text. Or you write your own Excel file decoder class. I've
only ever seen a good Excel _writer_ class.
Or if you have a Macintosh, you could "Print to PDF" and display that.
Downloading would be simply a matter of encoding the right document
headers and reading the file when you click on a link.
--
DeeDee, don't press that button! DeeDee! NO! Dee...
| |
| Robert Bravery 2006-05-22, 6:59 pm |
| Hi Michael,
I had four original thoughts,
1. display the XL file in the browser, but then not gauranteed everyone has
excel installed
2. Write the excel files to a PDF as you suggest, and allow the clients to
download. Could work, but have +- 100 XL files, would have to write a script
to automate.
3. Create a CSV file of the XL spread sheets, open that up with php and
create a html table.. Might have to script the exzcel save to csv.
4. Similar to above, CSV file, import to MYSQL, then create an HTM table
from MYSQL.
I was hoping that there might have been simpler ways, or other folks would
have a script or two, saving me from re-inventing the wheel.
ANy case, of the above, which would you most likley suggest
THanks
Robert
"Michael Vilain" <vilain@spamcop.net> wrote in message
news:vilain-476AD8.15041122052006@comcast.dca.giganews.com...
> In article <e4romg$9ee$1@ctb-nnrp2.saix.net>,
> "Robert Bravery" <robert@db2k.co.za> wrote:
>
users[color=darkred]
>
> You can't display them like they appear in Excel unless you export them
> as table text. Or you write your own Excel file decoder class. I've
> only ever seen a good Excel _writer_ class.
>
> Or if you have a Macintosh, you could "Print to PDF" and display that.
> Downloading would be simply a matter of encoding the right document
> headers and reading the file when you click on a link.
>
> --
> DeeDee, don't press that button! DeeDee! NO! Dee...
>
>
>
| |
| Michael Vilain 2006-05-22, 9:57 pm |
| In article <e4td0h$kr7$1@ctb-nnrp2.saix.net>,
"Robert Bravery" <robert@db2k.co.za> wrote:
> Hi Michael,
> I had four original thoughts,
> 1. display the XL file in the browser, but then not gauranteed everyone has
> excel installed
How will the browser interpet the XL file? Mine (Safari) doesn't know
what to do with it. Or, if the headers are correct, it will download
the XL file, run Excel, and open the file. I think you mean the latter,
no?
> 2. Write the excel files to a PDF as you suggest, and allow the clients to
> download. Could work, but have +- 100 XL files, would have to write a script
> to automate.
> 3. Create a CSV file of the XL spread sheets, open that up with php and
> create a html table.. Might have to script the exzcel save to csv.
> 4. Similar to above, CSV file, import to MYSQL, then create an HTM table
> from MYSQL.
>
> I was hoping that there might have been simpler ways, or other folks would
> have a script or two, saving me from re-inventing the wheel.
> ANy case, of the above, which would you most likley suggest
How much time have you got? Does this need to "scale" to more than 100
files? I'd think (4) would be the more universal solution.
[color=darkred]
>
> THanks
> Robert
>
>
> "Michael Vilain" <vilain@spamcop.net> wrote in message
> news:vilain-476AD8.15041122052006@comcast.dca.giganews.com...
> users
--
DeeDee, don't press that button! DeeDee! NO! Dee...
| |
| Robert Bravery 2006-05-23, 3:58 am |
| HI Michael
> How much time have you got? Does this need to "scale" to more than 100
> files? I'd think (4) would be the more universal solution.
>
>
Nope, probably only a few differences between the files, most are very
common. Set-up the exact same way, only differeing in one line, a header
describing the client. I would rather have the data in MYSQL, but my client,
does not want to do that at this moment. All he want is to put the spread
sheets onto the web so that his clients can see their statements
Robert
| |
| Ramin Rezai Rad 2006-05-29, 3:58 am |
| Robert Bravery schrieb:
> HI all,
> Newbie here. How can I display excel documents on my website, for our users
> to view and or download, using php
>
> Thanks
> Robert
>
>
Hi Robert,
for download, you can use http://pear.php.net/package/Spreadsheet_Excel_Writer.
But I bet you already know this :)
|
|
|
|
|