NavBar位于移动应用

时间:2016-03-07 11:01:26

标签: css

我要做的是在我的移动应用程序的底部放置一个导航栏,如果我滚动页面,则不会移动。我已尝试使用此代码,但之后我无法处理链接元素,书面文字并未与包含它们的框的中心对齐:

ul{
  list-style:none;
  text-align:center;
  position:fixed;
  bottom:0;
  border-top: 1px solid white;
  width: 100%;
  height: 40px;
  background: -webkit-linear-gradient(black,#404040);}
li{
  display:inline-block;
  height:40px;
}
li a {
  color:white; 
  font: bold 15px verdana;
  text-decoration:none;
  display:block;
  height:40px; }

HTML只是两个元素(Home和我们是谁)。 我能怎么做?谢谢! 编辑:从图片中可以看出,存在问题:文字未分配到中心enter image description here

0 个答案:

没有答案