首页前端开发HTMLhtml5 css3网站菜单实现代码

html5 css3网站菜单实现代码

时间2024-01-24 10:07:25发布访客分类HTML浏览593
导读:收集整理的这篇文章主要介绍了html5 css3网站菜单实现代码,觉得挺不错的,现在分享给大家,也给大家做个参考。 实现的难点在于:First-child,last-child 两个选择器,以后margin-left:-1px;的...
收集整理的这篇文章主要介绍了html5 css3网站菜单实现代码,觉得挺不错的,现在分享给大家,也给大家做个参考。

实现的难点在于:First-child,last-child 两个选择器,以后margin-left:-1px; 的应用,33%,34%宽度的技巧处理。

另外一个难点是:box-shadow:1px 0 0 #F1F1F1 inset; 的实现。

最后是:

复制代码代码如下:
background:-webkit-gradient(linear, left top, left bottom, From(#f9f9f9), to(#b6b4b4)); background:-moz-linear-gradient(top, #f9f9f9, #b6b4b4); background:-o-linear-gradient(top, #f9f9f9, #b6b4b4); background:linear-gradient(top, #f9f9f9, #b6b4b4);


复制代码代码如下:

!doctyPE htML>
html XMlns="a href="http://www.w3.org/1999/xhtml"> http://www.w3.org/1999/xhtml/a> " xml:lang="en">
head>
meta http-equiv="Content-type" content="text/html; charset=UTF-8"/>
tITle> html5,css3菜单/title>
style type="text/css">
.jikey_demo{ width:80%; margin:0 auto; background:#f1f1f1; }
.news_info{ margin-bottom:5px; border:1px solid #bbb; border-radius:5px; box-shadow:0 1px 0 #f1f1f1; }
.news_info a{ display:inline-block; width:33%; height:26px; font-family:"微软雅黑"; line-height:26px; text-align:center; color:#555; border-right:1px solid #ccc; box-shadow:1px 0 0 #F1F1F1 inset; }
.news_info a:first-child{ width:33%; box-shadow:none; border-radius:4px 0 0 4px; }
.news_info a:last-child{ width:34%; border-right:none; margin-left:-2px; border-radius:0 4px 4px 0; }
.news_info a:hover, .news_info a.current{ color:#208edd; background:-webkit-gradient(linear, left top, left bottom, from(#f9f9f9), to(#b6b4b4)); background:-moz-linear-gradient(top, #f9f9f9, #b6b4b4); background:-o-linear-gradient(top, #f9f9f9, #b6b4b4); background:linear-gradient(top, #f9f9f9, #b6b4b4); }
/style>
/head>
body>
div class="jikey_demo">
nav class="news_info"> a class="current" href="/news/"> 新闻1/a> a class="" href="/guide/"> 新闻2/a> a class="" href="/review/"> 新闻3/a> /nav>
/div>
/body>
/html>

声明:本文内容由网友自发贡献,本站不承担相应法律责任。对本内容有异议或投诉,请联系2913721942#qq.com核实处理,我们将尽快回复您,谢谢合作!

上一篇: html5 canvas实现圆形时钟代码分...下一篇:html5 自定义播放器核心代码猜你在找的html5相关文章 关于移动端h5开发相关内容总结2022-05-17html5教程-学表单的第二天2018-12-10html5教程-HTML5浏览器支持2018-12-10html5教程-HTML5智能表单2018-12-10html5教程-微信H5使用resLoader实现加载页效果2018-12-10html5教程-day01-初级-JS0-热身运动JS入门教程2018-12-10html5教程-html5shiv.js和respond.min.js2018-12-10html5教程-不同浏览器对于html5 audio标签和音频格式的兼容性2018-12-10html5教程-使用Html5实现手风琴案例2018-12-10html5教程-html5笔记2018-12-10 其他相关热搜词更多phpjavapython程序员load

若转载请注明出处: html5 css3网站菜单实现代码
本文地址: https://pptw.com/jishu/585286.html
html5的canvas实现3d雪花飘舞效果 html5 canvas实现圆形时钟代码分享

游客 回复需填写必要信息