PDA

View Full Version : double links for single click



gogu1988
Jan 20th, 2011, 02:30 PM
hi i am govardhan completed b.tech now getting training in TCS. i have one doubt i.e. what is the html code to open two url links for just only one click on an link
i mean if a person click on link click hear then two links should be open
i am new to this site if u have any answer for my problem please mail me the html code i will be thankful to you sir/madam
my email id is [email protected]
please help me

Riboflavin
Jan 20th, 2011, 02:41 PM
Sorry but this isn't possible with html. You may be able to do something with javascript/frames but with standard html, no.

Major Payne
Jan 21st, 2011, 02:49 PM
Maybe try...

Open Main Page and Affiliate's:


<p><a href="http://mainlinkhere/" onclick="window.open('http://affiliatelinkhere','newwin');" title="affiliate product's name"><img style="width: XXpx; height: YYpx; border: 0;" src="Path to image" alt="Text Description"></a></p>

You can change the "p" tags to div tags and style as needed.

sunfighter
Jan 21st, 2011, 08:17 PM
Major Payne got this one before i posted. His works great but it does over ride the page that has the original link - At lest it does in FF with tabs enables. This opens two separate tabs:

<a href="http://www.facebook.com" target="_blank"
onclick="window.open(&quot;http://www.google.com&quot;);>Link text</a></body>

Major Payne
Jan 22nd, 2011, 05:17 AM
I just never use target="_blanlk" as it is never used correctly. If you are using a plain old Transitional doctype, then it pretty much doesn't matter, but mine are Strict and XHTML so that attribute is invalid in those cases unless used correctly.

Lots of yeas/nays on the subject. Here's one ro start>

CodingForums (http://www.codingforums.com/showthread.php?t=152574) :D

sunfighter
Jan 22nd, 2011, 10:39 PM
Thank you Major Payne for a good read on the subject. Choices are great and now gogu1988 has one.