您当前的位置:中客资源站网络学院网页设计HTML/CSS → 文章内容 退出登录 用户管理
本类热门文章
相关下载
用CSS区分浏览器Firefox、IE6、IE7的特效代码
作者:本站整理  来源:站长网  发布时间:2007-7-22 0:17:17

减小字体 增大字体

用CSS代码来判断浏览器是Firefox、IE6、IE7??的网页特效代码

<!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>关于用CSS区分Firefox、IE6、IE7chinahtml.com</title>
 <style type="text/css">
 #example{color:red ;}/*firefox*/
 * html #example{color:blue;}/*ie6*/
 *+html #example{color:green;}/*ie7*/
 </style>
 </head>
 <body>
 <div id="example">在FireFox下应为红色,在IE6.0下应为蓝色,在IE7.0下应为绿色。</div>
 </body>
 </html>

        Ctrl+A 全部选择 友情提示:您可先修改部分代码,再运行

[] [返回上一页] [打 印]
文章评论 (评论内容只代表网友观点,与本站立场无关!)

用户名: 查看更多评论

分 值:100分 85分 70分 55分 40分 25分 10分 0分

内 容:

         (注“”为必填内容。) 验证码: 验证码,看不清楚?请点击刷新验证码