470,647 Members | 1,204 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,647 developers. It's quick & easy.

open a file in a new window

Hi,
can you please tell me how I can set up a script that would open a pdf
file when a button is clicked?
Can I add a "Close" and "Print" buttons to the file being displayed?

Thanks.
Jul 23 '05 #1
2 2738
Xerxes wrote:
Hi,
can you please tell me how I can set up a script that would open a pdf
file when a button is clicked?
Can I add a "Close" and "Print" buttons to the file being displayed?

Thanks.


<a href="yourfile.pdf" target="_blank">Click here to open the PDF in a new
window</a>

--
| Grant Wagner <gw*****@agricoreunited.com>

* Client-side Javascript and Netscape 4 DOM Reference available at:
*
http://devedge.netscape.com/library/...ce/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/a...ence_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-deve...upgrade_2.html
Jul 23 '05 #2
On Thu, 20 May 2004 18:44:01 GMT, Xerxes wrote:
can you please tell me how I can set up a script that would open a pdf
file when a button is clicked?
Can I add a "Close" and "Print" buttons to the file being displayed?


(chuckle) I had this image..
<http://www.physci.org/eg/dialog.jsp?text=Click+OK+to+print+our+468+pages%0D %0Aof+exciting+discount+offers%21&type=confirm>

Did you want to programatically click
'OK' as well? ;-)

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by NeverLift | last post: by
29 posts views Thread by wayne | last post: by
6 posts views Thread by qysbc | last post: by
6 posts views Thread by Filips Benoit | last post: by
1 post views Thread by Korara | last post: by
reply views Thread by warner | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.