ReeKo
11-05-2004, 08:52 AM
First off I want to say that I have very to NO knowldege of java. I"m pretty stupid with it actually...:o The sript I have below is what i"m using in a VBB forum. I'm trying to make it so that when users click on the Logo in the forums it opens a new window. I do know that in HTML the --- target="_blank" --- in the <hREF> line is what makes a new window appear if someone clicks on a hyperlink. IS it possible to add this -- target="_blank" -- line somewere below to make the hyperlink open a new window. And Please forgive me if I"m not making sense all this is new to me.. Thank you for your time.
Here is a link http://www.quadzoneforums.com/forums/ to the site with the animated Gif/logos at the top that I want to open a new window if someone clicks on them.
<!-- Begin
var how_many_ads = 4;
var now = new Date()
var sec = now.getSeconds()
var ad = sec % how_many_ads;
ad +=1;
if (ad==1) {
txt="";
url="http://www.quadzn.com";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/chromenew.gif";
width="280";
height="64";
}
if (ad==2) {
txt="";
url="http://www.quadshopatv.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/quadshopbanner.gif";
width="350";
height="45";
}
if (ad==3) {
txt="";
url="http://www.spidergrips.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/spider_top.gif";
width="480";
height="90";
}
if (ad==4) {
txt="";
url="http://www.shok-spotr.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/shokspotr_top.gif";
width="350";
height="100";
}
document.write('<center>');
document.write('<a href=\"' + url + '\" target=\"_top\">');
document.write('<img src=\"' + banner + '\" width=')
document.write(width + ' height=' + height + ' ');
document.write('alt=\"' + alt + '\" border=0><br>');
document.write('<small>' + txt + '</small></a>');
document.write('</center>');
// End -->
Here is a link http://www.quadzoneforums.com/forums/ to the site with the animated Gif/logos at the top that I want to open a new window if someone clicks on them.
<!-- Begin
var how_many_ads = 4;
var now = new Date()
var sec = now.getSeconds()
var ad = sec % how_many_ads;
ad +=1;
if (ad==1) {
txt="";
url="http://www.quadzn.com";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/chromenew.gif";
width="280";
height="64";
}
if (ad==2) {
txt="";
url="http://www.quadshopatv.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/quadshopbanner.gif";
width="350";
height="45";
}
if (ad==3) {
txt="";
url="http://www.spidergrips.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/spider_top.gif";
width="480";
height="90";
}
if (ad==4) {
txt="";
url="http://www.shok-spotr.com/";
alt="";
banner="http://www.quadzoneforums.com/forums/images/Header_logos/shokspotr_top.gif";
width="350";
height="100";
}
document.write('<center>');
document.write('<a href=\"' + url + '\" target=\"_top\">');
document.write('<img src=\"' + banner + '\" width=')
document.write(width + ' height=' + height + ' ');
document.write('alt=\"' + alt + '\" border=0><br>');
document.write('<small>' + txt + '</small></a>');
document.write('</center>');
// End -->