Jump to content

Convert to PDF


SkyRanger

Recommended Posts

I am trying to figure out how to create a script so that my members can upload a file .doc,.txt,.fdr etc and be able to convert it to PDF

 

I downloaded class.ezpdf and class.pdf but there are very little instruction on how to use it.  Any help would be greatly appreciated.

Link to comment
Share on other sites

There is a really cool PDF class www.fpdf.org which will create a pdf for you.  Not sure about how you would convert a Word document but converting a plain text file should be easy enough.  Simply read the data from the textfile into a variable and output this in your PDF document.  As for PDF conversion you may need to install PDFLIB on your server which if like me you are on a managed server, this simply wont be allowed.  My hosting company informed me that the install would affect the whole server and also the cost of the license would be too expensive. 

 

As I said before www.fpdf.org may help you and is really well documented with example code and tutorials.  Not sure if this really answers your question however.

 

Thanks

 

Steve (Blackpool)

Link to comment
Share on other sites

1. couple things I can think of.  I know that there are many good free available HTML to PDF converters. If they are submitting, .doc files, I know that WORD can save files as HTML. Perhaps have the person save them in webpage format, then you can convert them more easily.

I have used, and am quite familiar with  http://www.tufat.com/s_html2ps_html2pdf.htm, so if you decide to go that route then I could provide assistance.

 

2. Another idea, I don't have as much familiarity with is, I know there are PDF distillers, where they can convert documents, however sometimes they requires the file to be converted into .ps before they can convert to .pdf  and as well they most likely require licensing.  But what would be done is when the user uploads the file, you would move it into the /in/ folder for the distiller, then there is an /out/ folder which would have the converted pdf files. Mind you I have no experience with this, so use this information at your own whim.

 

3.  On a third note a quick search yielded  http://www.wynia.org/wordpress/word-to-pdf-converter-in-php-word2pdf/. Looks like it could be really easy, just need the server to be on a windows machine I think, with Openoffice Installed of course. Again I have no experience with this but you could research it some more.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.