一个词在标题中不起作用 [英] One word doens't work as the others in the header

查看:67
本文介绍了一个词在标题中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有谁知道为什么登录不会将自己定位为其他词语?另外,白线没有显示出来。



无论如何,这是编码。



HTML



Does anyone know why the "Sign In" won't position itself as the other words? Also the white line is not showing as on the other words.

Anyhow, here is the coding.

HTML

<html>
<head>
<link rel="stylesheet" type="text/css" href="ep.css">

</head>

<body>

<nav id="nav-1">
  <a class="link-1" href="#">logo</a>
  <a class="link-1" href="#">Buy</a>
  <a class="link-1" href="#">Rent</a>
  <a class="link-1" href="#">Mortgage</a>
  <a class="link-1" href="#">Moving</a>
  <a class="link-1" href="#">News</a>
  <a class="link-2" href="#"> Sign In</a>
</nav>
<img src="images/si.jpg" alt="Mountain View">




</body>
</html>







CSS






CSS

@import url(http://fonts.googleapis.com/css?family=Raleway);
body {
  margin: 0px;
}
nav {
  margin-top: 0px;
  padding: 20px;
  text-align: left;
  font-family: Raleway;
  
}
#nav-1 {
  background: #6CC204;
}


.link-1 {
  transition: 0.3s ease;
  background: #6CC204;
  color: #ffffff;
  font-size: 16px;
  text-decoration: none;
  border-bottom: 0px solid #6CC204;
  padding: 20px 0;
  margin: 0 20px;
}
.link-1:hover {
  border-bottom: 4px solid #ffffff;
  padding: 6px 0; 
}

.link-2 {
  transition: 0.3s ease;
  background: #6CC204;
  color: #ffffff; 
  font-size: 16px;
  text-decoration: none;
  border-bottom: 0px solid #6CC204;
  padding: 20px 0;
  margin: 0 20px;
  left:1430px;
  position:absolute;
  
}
.link-2:hover {
  border-bottom: 4px solid #ffffff;
  padding: 6px 0px; 
}


img {
    position: absolute;
    left: 1400px;
    top: 20px;
   
}

推荐答案

将其改为......

Change it to...
<a class="link-1" href="#"> Sign In</a>


这篇关于一个词在标题中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆