|All requests||>||Store PDF as binary in Database and r...||>||Request new recommendation||>||Featured requests||>||No recommendations|
by muabshir - 5 years ago (2017-03-13)
I want to STORE PDF in database as binary and called it as PDF or Word or HTML formate
1. by Dave Smith - 5 years ago (2017-04-30) Reply
pdf is already binary. You can use file_get_contents() to read the file into a variable and then save that in the database as a BLOB (binary large object).
To display it in the browser, you just need to send the appropriate content headers before you echo the data.