View Full Version : open all link in blank page

04-26-2004, 08:13 PM
can anyone provide me with a jscript or maybe css tag to have all links on a page opened in a blank window?

thanks in advance

04-26-2004, 08:33 PM

If you want them to open in a new window and a new instance of a window for each link that is clicked after the first. Change the window name each time you call the function. Keep all the names the same and it will replace the contents after the first pop-up.

<script type="text/javascript">

function newWin(url,window_name)
var my_win=window.open(url,window_name)
return false;
<a href="#" onclick="newWin('http://www.codingforums.com','win1');">Coding Forums</a>
<a href="#" onclick="newWin('http://www.codingforums.com','win2');">Coding Forums</a>
<a href="#" onclick="newWin('http://www.codingforums.com','win1');">Coding Forums</a>


04-26-2004, 08:55 PM
no, that's no good..
I need something that apply at all links without specifying nothing in them..

Willy Duitt
04-26-2004, 09:43 PM
It's not advisable but you could try:
<BASE TARGET="_blank">


04-26-2004, 10:14 PM
this goes in the header by the way...

04-27-2004, 11:58 AM
hey guys thanks very much for help, the solution

<BASE TARGET="_blank">

is what i was searching for.

isn't possible to assign that as a css style?

04-27-2004, 01:42 PM
isn't possible to assign that as a css style?

er .... no. :p

styles are for presentation formatting, not presentation mark-up. the former deals with the actual look, not the code that builds the interface.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum