The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

> Javascript To Open PDF From Select Option
joehesse
post Sep 2 2018, 11:19 AM
Post #1





Group: Members
Posts: 7
Joined: 5-July 18
Member No.: 26,667



Hi,
I have the following in my html file: The file was generated from php on the server.

<select id="MyFiles">
<option value='dir/file1.pdf'>file1</option>
<option value='dir/file2.pdf'>file2</option>
<option value='dir/file3.pdf'>file3</option>
</select>

In the above, "dir" is a folder above the html server root directory.
When the user clicks on a row I would like the pdf to open in a separate tab. What jquery or javascript do I need to do this?

Thank you,
Joe
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Posts in this topic


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 18th May 2024 - 12:20 PM