C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Resources » Code Snippets » Html »

PDF file load into HTML page


Posted Date: 18 Jun 2009    Resource Type: Code Snippets    Category: Html
Author: Varun BansalMember Level: Gold    
Rating: 1 out of 5Points: 8



We can embedded PDF File into HTML page like that QuickTime movies, Flash, MPEGs, and WAV files.


So wen can use the trick of load PDF into HTML page on Page load using embed tag as following:


< embed src="abc.pdf" width="500" height="650" > </embed >


here src is use for source file of pdf file. and width and height is use for set display with and height. we can use the % instead of pixels.



Just a note, < embed > is not an XHML standard, although it is supported by many browsers.

Your code to meet the XHTML standard then you better use the < object > tag instead < embed > tag.

< object type="application/pdf" data="abc.pdf" width="600" height="750" < >/object >

If the browser do not support < object > or cannot find its program then you can add anything as an alternative Between the opening and closing tags.
For example, you can add the link to the PDF file if it cannot be viewed in the page:


< object type="application/pdf" data="abc.pdf" width="600" height="750" >
Click < a href="abc.pdf" > here </a > to view the file </object >


You can add the parameter like that:

For toolbar: 1 = show, 0 = not show

For navpane: 1 = show, 0 = not show

For scrollbar . 1 = show, 0 = not show



Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Sign In to add tags.
Pdf open on load page  .  Pdf open into html page  .  

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: Hyperlink in Html
Previous Resource: Flash File play
Return to Discussion Resource Index
Post New Resource
Category: Html


Post resources and earn money!
 
More Resources



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use