Home > Web Front-end > HTML Tutorial > 导航栏的制作问题_html/css_WEB-ITnose

导航栏的制作问题_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:22:54
Original
1119 people have browsed it

在看视频学习制作导航栏的时候,遇到以下问题,烦请各位大大指导:

视频的代码以及效果如下




接下来是我的代码:



普通的blog


普通的blog,普通的新手





效果如下:

问题一:同样一段的CSS,我的Li居然是无法居中?
问题二:为啥她的a:hover有效果,而我是啥效果都没?
自己测试过,重新按照视频做了几次,结果还是没变。请教各位大大,我的问题是出在哪里?
谢谢!


回复讨论(解决方案)



nav ul{
width:1100px;
height:60px;
margin:0px auto;
background:red;
}

nav ul li{
widht:70px;      width的t和h倒了 
height:60px;
float:left;
text-align:center;
}

nav ul li a:hover{
display:block;
height:60px;
background::#3f3f3f;       多了个:

nav ul{
width:1100px;
height:60px;
margin:0px auto;
background:red;
}

nav ul li{
widht:70px;      width的t和h倒了 
height:60px;
float:left;
text-align:center;
}

nav ul li a:hover{
display:block;
height:60px;
background::#3f3f3f;       多了个:


谢谢!居然犯了这么低级的错误!真丢人哎。。
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template