Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Image Zoom

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #37310
    CameronDuthie
    Participant

    Hi there,

    I was hoping someone here could help with this problem im having. I’ve managed to set up an image for when the user rolls over it, it zooms out. I would like to add the same functionality to a button, so when the user rolls over that button the image zooms out, but i can’t seem to get the darn thing to work.

    I’ve set up a fiddle to help explain what i mean. http://jsfiddle.net/CameronDuthie/byrHL/

    Any help would be greatly appreciated,

    Many Thanks,

    Cameron

    #99828
    Jozsef K.
    Participant

    well,just change the

    $(‘#right img’).hover to $(‘.btn-torq’)

    $this=$(this) to $this=$(‘#right img’)

    Bytheway, great idea, amazing effect.

    #99842
    CameronDuthie
    Participant

    @jozsef Thank you so much for your help i really appreciate that. It works a treat, I’m a complete novice when it comes to javascript. Thanks for the compliment. :)


    @kgscott284
    Thanks for the advice and your comment. What advantages are there with using % over px? I’m not sure what you mean by flexible?

    #99846
    Vermaas
    Participant
    #99969
    CameronDuthie
    Participant

    Yes, many thanks @vermaas. I think i now have a clearer idea of what flexibility means in javascript.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.