PDF to HTML conversion---PHP
I need some clarification to covert the pdf file to html file using php.
I have no idea to convert the files using php. Please send me any ideas and your suggestion how to convert the pdf files to html ..
PHP does not have any built-in functions that directly support this. Writing your own would be far from trivial. My recommendation would be to search the web for existing scripts that do this conversion.
I can't see how it could even be possible. PDF documents have layout while HTML documents do not; and PDF documents have a page size while HTML documents do not even have pages. I would make a comparison between this and doing a .doc to a .txt conversion where all formatting would be lost in the process. Even a sledgehammer like Google with its massive resources can't get this right. Just try the convert pdf >> html feature on its search page to see what I mean.
Obviously if the converssion were the other way around (HTML >> PDF... .txt >> .doc) it would be easy and there is plenty of software that can do this... fpdf for example.
I have seen this done on google - i dont know how...
[PDF] Owner’s ManualFile Format: PDF/Adobe Acrobat - View as HTML
Have a look at this example...
Dont know if that helps, but hey.
That's exactly what I am talking about. If you look at the html documents they are a terrible mess.
Originally Posted by CAT web design
And try looking at the html itself... absolute gobbledegook.
Last edited by bokeh; 07-27-2006 at 04:16 AM.
If you just want to do a one-off conversion, check out this page: http://www.adobe.com/products/acroba...linetools.html
Why convert PDF to HTML.
You can write web pages in HTML or PDF. PDF ones can contain embedded fonts and will always display exactly as shown whereas HTML wont.
Both support links from one page or position on a page to another.
PDF supports everything for the web that HTML does and a few additional features that can't be done using HTML.
Online Tool to Convert Webpage(HTML) into PDF Format
You may be saving a webpage as a html file to read it offline. But instead of saving it as html, you can convert a webpage into pdf format. This can prove to be more effective way of viewing data offline.
http://html-2-pdf.com is an online tool to convert webpages into PDF(Portable Document Format) documents. It’s basically an online converter which could transform any websites to a PDF document. Generally it could be more useful if you want to print a website.
for more info read my blog http://blogbyanoopsharma.wordpress.com/
The link below will has a script to convert the PDF file to HTML, this may help you, check it out.
See this page about xPDF.
I use this function to transform PDF to text which give good results...
The package xpdfbin-win-303.zip contains to pdfimages, pdffonts, pdfimages...
$o=shell_exec('pdftotext -enc UTF-8 '.$pathFile.' pdf.txt');
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)