You are here: Re: help on word document « PHP Programming Language « IT news, forums, messages
Re: help on word document

Posted by dkruger on 08/09/07 13:39

On Aug 9, 8:03 am, piyush <piyush.pla...@gmail.com> wrote:
> i have to show the contents of a word document
> i tried readfile() but that shows many binary characters of word
> document which looks odd
> plz suggest me any idea to show content of a word document just as
> Google Docs & Spreadsheets shows after uploading a word document on
> the fly.
>
> plz help me its urgent suggest any way

What you need to be sure to do in your script that reads the file is
set the headers so the browser will know what it is supposed to be
doing with the file, instead of displaying as plain text. If you add
the headers like:

header("Content-type: applicaton/msword");

It will probably work like you are wanting it to, to get the word
document to display in the web browser. The header has to be sent
prior to sending any other data output in the script. Hope it helps.

Thanks,
David

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация