用图片代替文字时解决方法_主要应用于SEO或者在不支持CSS的浏览器下使用

<! DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" >
< html  xmlns ="http://www.w3.org/1999/xhtml" >
< head >
< meta  http-equiv ="Content-Type"  content ="text/html; charset=gb2312"   />
< title > 用图片替换文字 </ title >
< style >
h1
{
    background-image
:url(http://www.58ka.com.cn/webui/images/sitelogo.gif);
    background-repeat
: no-repeat;
    height
:100px;
}

a
{ display:none;}
</ style >
</ head >

< body >

示例: CSS使用图片代替文字时需要
< br  />
常用站网站LOGO上
< h1 >< href ="http://www.58ka.com.cn" > 网络游戏新手卡示例 </ a ></ h1 >



</ body >
</ html >


马克 2008-05-29 12:06 发表评论

你可能感兴趣的:(css)