0

I wish to embed a PDF into my HTML page ensure it remains up to HTML5 standard.

I tried embed and object but the only way I could get it to work was using iframe with src="file.pdf" (I can't get html to print here)

I'd like to put the file in a folder and have tried so many combinations which won't work. I thought (wrongly) it'd be just folder/file.php but it says it can't be found. I've tried using the c:/ path to the file no difference. I wanted to use relative paths so when it's hosted it'll work grand.

I'm using wamp as my localhost while building and my project is held within the www folder.

It's driving me insane so if anyone could shed any light I'd be eternally grateful.

  • Check out this question. http://stackoverflow.com/questions/291813/recommended-way-to-embed-pdf-in-html – Ed T. Apr 20 '14 at 22:24
  • I saw this alright, I went for the "This is quick, easy, to the point and doesn't require any third-party script:" All I get is The requested URL was not found on this server. Thanks for help :) alpreciated – user3554920 Apr 20 '14 at 23:26

1 Answers1

0

This is one of the answers proposed on this question: Recommended way to embed PDF in HTML?

Works in FF, IE7+ and chrome.

<embed src="http://yoursite.com/the.pdf" width="500" height="375">

Community
  • 1
  • 1
Ed T.
  • 1,039
  • 2
  • 11
  • 17
  • I checked that link out, my problem is that the src always returns The requested URL was not found on this server. I've tried http://127.0.0.1/folder/file.pdf but still doesn't work. Thanks for help appreciated :) – user3554920 Apr 20 '14 at 23:28