Quick Javascript Pop Up Question...... help

Discussion in 'OT Technology' started by Silent, Jan 17, 2003.

  1. Silent

    Silent New Member

    Joined:
    Sep 20, 2001
    Messages:
    1,831
    Likes Received:
    0
    Location:
    Chicagoland
    I'm simply trying to link a thumbnail to the full size image by using this command:

    Code:
    <a href="Attributes/Images/mycar/pics/01.JPG" ONCLICK="window.open('Attributes/Images/mycar/pics/01.JPG', 'popup', 'toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=no,copyhistory=no,width=640,height=480')" target="_self"><img src="Attributes/Images/mycar/pics/thumbs/tn_01.jpg" width="78" height="78" border="0"></a></td>
    
    But when I click on the image, I do get the popup window I want, but the main page that you click on also goes to the same pic, so now I have 2 of the same images on there.....

    Heres the link so you can see for urself.. Just click the first picture

    http://www.lswon.com/2000transam.htm

    So what am I doing wrong?
     
  2. Scud

    Scud I'm an aquired taste.

    Joined:
    May 24, 2001
    Messages:
    1,240
    Likes Received:
    0
    Location:
    Pennsylvania
    Code:
    <a href="Attributes/Images/mycar/pics/01.JPG" ONCLICK="window.open('Attributes/Images/mycar/pics/01.JPG', 'popup', 'toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=no,copyhistory=no,width=640,height=480')" target="_self"><img src="Attributes/Images/mycar/pics/thumbs/tn_01.jpg" width="78" height="78" border="0"></a></td>
    
    You have a target=_self in there.
     
  3. Silent

    Silent New Member

    Joined:
    Sep 20, 2001
    Messages:
    1,831
    Likes Received:
    0
    Location:
    Chicagoland
    Even if I take it completely out (ie. remove the target=_self) it still happens :dunno:
     
  4. Nocera

    Nocera ...

    Joined:
    Aug 9, 2000
    Messages:
    1,307
    Likes Received:
    0
    Location:
    Long Island, NY
    Try something like
    Code:
    window.open('Attributes/Images/mycar/pics/01.JPG','pic','resizable,scrollbars=no,width=640,height=480');
    
     
  5. Bono

    Bono Guest

    Replace: href="Attributes/Images/mycar/pics/01.JPG"

    With: href="#"
     
  6. Silent

    Silent New Member

    Joined:
    Sep 20, 2001
    Messages:
    1,831
    Likes Received:
    0
    Location:
    Chicagoland
    Thank You!!

    :bowdown:
     

Share This Page