Forums

HOWTO question - highlights (2 posts)

  1. asilverstone
    Member
    Posted 2 years ago #

    Some web pages, for example digitalnature.ro , have the feature that when you hover over a part of the page, that part gets colorized, while other parts get greyed. Anyone knows how to do it?

  2. fldtrace
    Member
    Posted 2 years ago #

    That's an interesting technique I haven't used yet, but after I took a look to the code, it seems he use 2 images.

    One is setup for a tag and the other one to span tag from within a tag.

    link to image

    With css, he moves the background position:

    a.project.itvizion span.hover {background-position: center bottom}

    With JavaScript he controls the opacity for fading effect, but I think there is a script for that.

    That guy is good, by the way. Same country like me :)

Topic Closed

This topic has been closed to new replies.

About this Topic