Forums

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

Home Forums JavaScript Anchor Link effect on mouse down

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

    In my nav bar, I’d like to have a mousedown effect on each button. I looked for a way with JavaScript (on google) but couldn’t find any that did what I wanted.
    Could somebody please post some code?

    (I would like the effect to be sort of like the Apple website)

    #84402
    furrball1383
    Member

    you mean you want the buttons to change on hover on click and in the regular position?

    #84404
    Billy
    Participant

    The button changes on hover, and when active.
    I want it to change when the mouse button is pressed down. (onmousedown)

    #84406
    Rob MacKay
    Participant

    Well you don’t need Javascript to do that…

    a:hover

    a:active

    in CSS will sort that out – you only need Javascript when you want to implement some sort of animation (without using CSS3)

    #84408
    Billy
    Participant

    Thanks. I’d been using divs within anchor links, but realised that I don’t need the divs anymore.

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