Skip to content
Advertisement

Tag: pdf

Get properties of a pdf file by using PHP

I have on pdf document. I want to print the details of pdf like page size by using php. I have this code This is my code can any one help regarding this. Thanks in advance Answer First check your pdfinfo’s path, if you don’t have it: XPDF… so then change your code: If you use Linux: $pdfinfo_path = “/path/to/pdfinfo”;

correct PHP headers for pdf file download

I’m really struggling to get my application to open a pdf when the user clicks on a link. So far the anchor tag redirects to a page which sends headers that are: this doesn’t seem to work, has anybody successfully sorted this problem in the past? Answer Example 2 on w3schools shows what you are trying to achieve. Also remember

How to extract images from a PDF in their original format

I’m using pdfimages -j bar.pdf /tmp/image to extract images from a PDF. My objective is to get them in their raw state as they were added. So If it was a .tif I’d like to get a .tif, if it’s a jpg I’d like to get a .jpg. I keep getting .ppm for everything I extract. Is it possible to

How to make files not shareable?

I am developing a website with php that is about uploading and selling/buying pdf documents. Of course, I need to program it in a way that makes it impossible (or at least very hard) to copy the purchased documents. Do you know of any mechanism to do this? Is it a programming issue or rather a pdf issue? Also, are

Convert PDF to JPEG with PHP and ImageMagick

I’m using a litte script to convert PDF to JPG. That works but the quality is very poor. The script: One more thing, I want to keep the original size of the PDF but the conversion crops the size of the JPG. Answer It can be done using setResolution, but you need to do it before loading an image. Try

Merge PDF files with PHP [closed]

My concept is – there are 10 pdf files in a website. User can select some pdf files and then select merge to create a single pdf file which contains the selected pages. How can i do this with php?

Advertisement