On click Href image question- Urgent

Discussion in 'JavaScript' started by cynia, Apr 7, 2011.

  1. #1
    Hello guys


    I want to ask you if something


    I got this code

    <a href="LINK--LINK-LINK"   target='_blank'><img class="ressssclass" width="300" height="250" src="http://MYIMAGEURL" alt="IMAGE" /></a>
    Code (markup):

    I want this after clicking to redirect the main window the click happened to my main page


    What should i do to manage this?


    regards
     
    cynia, Apr 7, 2011 IP
  2. Jan Novak

    Jan Novak Peon

    Messages:
    121
    Likes Received:
    5
    Best Answers:
    1
    Trophy Points:
    0
    #2
    I am not sure what you exactly want, try:

    
    <a onclick="window.location.href='http://google.com'" href="LINK--LINK-LINK"   target='_blank'><img class="ressssclass" width="300" height="250" src="http://MYIMAGEURL" alt="IMAGE" /></a>
    
    Code (markup):
     
    Jan Novak, Apr 7, 2011 IP
    cynia likes this.
  3. cynia

    cynia Well-Known Member

    Messages:
    890
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    140
    Digital Goods:
    1
    #3
    Thanks a lot :) i managed to solve it :) REP+ added
     
    cynia, Apr 7, 2011 IP
  4. anupkumarpandey

    anupkumarpandey Peon

    Messages:
    10
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    <a href="http://www.simoniac.co.in"><img class="ressssclass" width="300" height="250" src="http://MYIMAGEURL" alt="IMAGE" /></a>
    in place of http://www.simoniac.co.in written ur site url and enjoy with this code.
    if any other problem then contact at my mail id.
    Anup kumar pandey
    anupmca007@gmail.com
     
    anupkumarpandey, Apr 10, 2011 IP
  5. cynia

    cynia Well-Known Member

    Messages:
    890
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    140
    Digital Goods:
    1
    #5


    I dont see anything special on your code
     
    cynia, Apr 13, 2011 IP