Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
279 views
in Technique[技术] by (71.8m points)

html - Opening a new tab to read a PDF file

I am probably missing something simple here, however i will ask anyway. I have made a link to open up a PDF file, however it opens up in the current tab rather than a new one. What code shall i use in HTML to open a new tab to read the PDF file.

<div class="footer_box_content">
    <div class="cleaner_h10"></div>
    <p>Many  thanks  to  everyone  who cleared snow and ice during the cold spell in February.
    Should Arctic conditions return, each block has a shovel and a jar of rock salt  to  clear  the  steps. 
    Please click more to read the full newsletter.</p>
    <div class="button_01"><a href="newsletter_01.pdf">Read more</a></div>
</div>
question from:https://stackoverflow.com/questions/16925481/opening-a-new-tab-to-read-a-pdf-file

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
<a href="newsletter_01.pdf" target="_blank">Read more</a>

Target _blank will force the browser to open it in a new window


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...