我是 html 的新手,所以我试图制作按钮,但我似乎无法摆脱链接中的下划线。这是我的代码:
<html>
<style>
body{
background-color: black;
}
a{
border: 5px solid white ;
border-radius: 20px;
font-size: 50px;
position: absolute;
bottom: 600px
text-decoration: none;
color: white;
transition: 0.3s ease-in-out;
background-color: black;
padding: 50px
}
a:hover {
color: white;
transition: 0.3s;
text-decoration: none;
font-size: 53px;
}
</style>
<title>BUTTON TESTING</title>
<a href=https://www.youtube.com >F.A.Q.</a>
</html>
最佳答案
在您的 CSS 代码中它缺少一个分号。
a{
....
bottom: 600px; //this line
text-decoration: none;
....
padding: 50px; //this line also
}
希望它能奏效。
关于html - 我无法摆脱下划线,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42453090/