I have a posts page which stores every individual blog. And each blog has a pdf file. I can upload the pdf via the blog page but when I execute my code through the for-loop on posts - post.file_doucment_path it just shows the pdf file location. Do I need to add a seperate js pdf reader package to get it working? Cheers.
To get started, login to your WordPress admin area and then go to Media. After that, click the “Add New” button. Simply drag and drop your PDF file in WordPress or click the “Select Files” button to upload it. After that, the PDF file will be uploaded to your WordPress website.
Google Docs enables you to embed your PDF document in your Blogger post. You need to upload your PDF file to Google Docs and update the visibility options. Your PDF includes File tools to produce the HTML embed code of the URL address needed for your Blogger post.
HTML5 <object>
element can embed PDFs in a page without an external library.
<object data="the.pdf" width="1000" height="1000" type='application/pdf'/>
Just replace "the.pdf
" with your file document path with Jekyll syntax.
e.g.<object data="{{ post.file_document_path }}" width="1000" height="1000" type='application/pdf'/>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With