¼ | ע
17վ վҳ ̳̽ Css Sprite̳

Css Sprite̳

ΪʲôҪʹCss Sprite

ΪʲôҪʹCss Sprite

1. Css Sprite

ͼԭľΪʲôҪһٰǼϵһͼȥأ

ʵҳļйأһ˵һվﲢֻһСͼ꣬ijվҳһʮСͼ꣬ôҳʱĵԾͻᷢʮ

ÿӦһСͼͼƬЩСͼ궼һŴͼôֻ跢һ

᲻һЩɻȻʮһ󣬵ͼƬСҲʮĻûʵԵĸı䰡

ʵͬһʱصԴ޵ģһԼʮͼ꣬ͲͬһʱرԴˣҳҲȻҳļٶȡ

2. ٸ

ٸеİ⣺

ԵʮݮǻÿùһȻʮأǻһ԰ʮݮùأ

Ȼ˵һʮõĶˣΪݮֶСһʮһһʮ˻ˡ

Ǵ󲿷ֻʱ䶼õԵʱ䣬ƶٶԽ磬пڵݻߵźŲȶĵطȥվ

½ͼƬϲһͼƬֻһͿԽԴԴȫأСӵģƶ˵Ϊԡ

3. Css Sprite

  • ҳ http  Css Spriteܹܺõؼҳ http 󣬴ӶҳܣҲŵ㣬Ҳ䱻㷺ӦõҪԭ

  • ͼƬĴС Css SpriteܹͼƬĴС3 ͼƬϲ 1 ͼƬĴС 3 ͼƬĴСҪС

  • ͼƬ ͼƬϵţֻһCss SpriteͿˣҪÿһСԪؽӶ˵ͷĴ

  • ⡣ ֻҪһŻͼƬ޸ͼƬɫʽҳķͿԸı䡣άӷ㡣

4. С

Ѿ˽ΪʲôҪ"һ"İСͼƬڴͼƬ

һЩ˵ HTTP2 ĵּѾʱˡ

ôЩǷΪأ뿴һСڡ

ض