Help with a menu

Discussion in 'CSS' started by jakoob, Feb 3, 2010.

  1. #1
    we're using two images with a hoover effect, one smaller and one somewhat bigger. But when I hoover the image the larger one is really poor quality, why?

    http://adata.worldwebmastersforum.com/
     
    Last edited: Feb 3, 2010
    jakoob, Feb 3, 2010 IP
  2. pmek

    pmek Guest

    Messages:
    101
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You should never resize images using css. Instead, just crop the image to the size you need and use it that way. Images resized via css will never look good quality, and can be detrimental to your page load times.
     
    pmek, Feb 3, 2010 IP
  3. jakoob

    jakoob Well-Known Member

    Messages:
    502
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    136
    Articles:
    1
    #3
    We dont resize we switch between to images
     
    jakoob, Feb 3, 2010 IP
  4. pmek

    pmek Guest

    Messages:
    101
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #4
    It's because you're doing it wrong!

    You can't change a background image of an img, the original img will still be above the background. You need to set the img as a background image on the <a> tag.

    To be honest though, it isn't a very nice effect when things resize on hover, it makes all the surroundings move around and is generally quite annoying.

    Try using sprites - have a read of this tutorial - http://www.ehousestudio.com/blog/view/css_sprite_navigation_tutorial
     
    pmek, Feb 3, 2010 IP