homepage Welcome to WebmasterWorld Guest from 54.205.254.108
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
pdf's in web pages
Drag_Racer




msg:3431505
 7:36 pm on Aug 24, 2007 (gmt 0)

I will be embedding a pdf document into a web page. I am creating the pdf doc on the fly and will be used as a preview for the user of the final product. Parameters are past to the server via ajax to create the pdf, then js updates the container in the html doc once the pdf file is ready.

I rarely use pdf's for web stuff so I don't have a lot of experience with them, but its just the best option for this case.

My question is, should I use an 'object/embed' tags or use an 'iframe' to display the pdf? My first guess is to use an object/embed tags so I can add a plugin path and an alternate url for no plugin.

any thoughts?

 

phranque




msg:3431654
 12:23 am on Aug 25, 2007 (gmt 0)

i am not aware of any object/embed solution for pdf's yet.
an iframe might work, but frames are frames...

Preeminent




msg:3432782
 12:25 am on Aug 27, 2007 (gmt 0)

hmmm, yes, I am about to do a resume in pdf format and was wondering what would be the best way to display it. So far, I am just going to have a link to the pdf file. I cannot, for the life of me find it, but I recall seeing an ad for a program or site that let you embed pdf files right into your page without visitors having to click on any link or download anything.

Drag_Racer




msg:3433904
 3:20 am on Aug 28, 2007 (gmt 0)

if your just going to display the pdf, I would suggest you convert it to an image file, such as a jpg or png file. just search for 'pdf converter' or 'PDFtoJPG' or 'PDFto PNG' or something along those lines and you'll find stuff to do it.

I will be offering this as an option for users without the pdf plugin, but for my project the pdf is the best option. I will probably be using an iframe to display the pdf doc as Firefox 1.5 had some issues with pdf's in the 'object' tag. I'm not sure what caused it, but I think it was due to my firewall not allowing the pdf plugin access to the internet and I didn't get a popup notice when the pdf was in the object tag, iframed I did.

pageoneresults




msg:3433907
 3:28 am on Aug 28, 2007 (gmt 0)

I cannot, for the life of me find it, but I recall seeing an ad for a program or site that let you embed pdf files right into your page without visitors having to click on any link or download anything.

A framed environment will allow you to do exactly what you want to do. An <iframe> is perfect for this situation. Just set the src to the .pdf and be done with it. Those who have reader installed will see the pdf appear in the <iframe> without any interaction on their part. The src content will load as soon as the page is accessed.

You can also do some fancy schmancy stuff with CSS and open it inside a scrolling div that's hidden until activated, etc.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved