I have a hyperlink with contains third party website link. I want to open this link in new tab with print command. How can i do this? Suppose:
<a href="www.google.com" target="_blank">Print</a>
Note: I know how to open a link in new TAB/Window. I want to know how to open with PRINT DIALOG.
Open in a new tab To open a link in a new tab, click the link by pressing down your middle mouse button, or right-click the link and select Open link in New Tab.
in mac: Cmd+click and in windows: ctrl+click will open new tabs in the background.
You can easily set external links to open in a new tab in WordPress. In the Classic Editor, just insert your link and click Link Options to open the advanced insert link popup. Then check the box labeled “Open link in a new tab.”
Use target="_blank" to Open Link in New Tab in HTML We can use the target attribute in the anchor tag to open a link in a new tab in HTML. The _blank value in the target attribute of the anchor tag opens the link in the new tab.
You could try something like this:
<a href="javascript: w=window.open('http://yoursite.com/LinkToThePDF.pdf'); w.print(); w.close(); ">print pdf</a>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With