InMotion Hosting Support Center

execute php within pdfs

Category: Phplist

2014-05-27 8:58 pm EST

Hits: 23
Is it possible to execute php within pdfs ? The purpose is to limit the access to these files. The program requires executable files to work.

You must login before you can ask a follow up question.

You must login before you can submit an answer.



11,186 Points
2014-05-28 7:41 am EST
This is not something that would be possible as PDF files are a completely separate type of file.

You must login before you can post a comment about this answer.

Ok got ya, I received an answer for a workaround and am hoping you can steer me to the php that I need. I was told to "create a PHP file for each one that will read the PHP and output it to the browser. That way you can protect the PHP file that outputs the PDF file and there is no way to download it directly." My question is what would the code be to do this? Can you steer me or tell me a script that would do this. I am a newby/non programmer. Much appreciated. - Brian
19 Points
2014-05-28 9:44 am EST
where it says "for each one" means each PDF.
19 Points
2014-05-28 9:46 am EST
Anything displayed within a browser can technically be downloaded by simply saving the page as HTML. Could you clarify your specific needs and exactly what you are trying to accomplish?

I also highly recommend hiring a developer as it sounds like what you are trying to do may need a significant amount of development.
11,186 Points
2014-05-28 11:15 am EST
Like this Question?

Support Center Login

Social Media Login

Social Login Joomla

Need more Help?


Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail:
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!