gpt4 book ai didi

html - 按钮不会出现在网页中?

转载 作者:行者123 更新时间:2023-11-28 00:46:42 25 4
gpt4 key购买 nike

我厌倦了在主搜索表单中添加搜索按钮,但出于某种奇怪的原因,在我保存和刷新后没有任何显示,我将此按钮编码为与该站点的另一个按钮完全相同,但它不可见,有任何想法吗?我不确定它出了什么问题,也真的不确定如何修复它,是不是我编写代码的方式导致了问题,有人知道我如何解决它吗?感谢您的所有帮助和建议,谢谢提前!

/* color:#00a786 lighter green */
/* color:#005242 dark green for buttons */
/* color:003027 dark green background */




*{
margin: 0px;
padding: 0px;
box-sizing: border-box;
}
html{
background-color: #fff;
}

body{
background: #ede6e6;
margin:0 auto;
font-family: arial, helvetica, sans-serif ;
}

a{
text-decoration: none;
color:#fff;
}
li{
display: inline;
padding: 10px;
font-size: 16px;
color:#fff;
}
/* --------------------------------HEADER------------------------------------- */
header{
background-image:linear-gradient(rgba(0, 0, 0, 0.7),rgba(0, 0, 0, 0.7)), url(../img/heder_photo_2.jpg);
background-size: cover;
background-position: center;
right:-20px;
left: -20px;
min-height: 100vh;
margin-bottom: 300px;
overflow-x: hidden;

background-attachment: fixed;
position: absolute;
z-index: 80;

}

.row{
padding-top: 40px;
border-bottom: 2px solid white;


}

}
/* --------------------------------TOP-LEFT------------------------------------- */
.top-left{

float:left;
}
.top-left ul {
font-size: 16px;
padding-left: 150px;
padding-top: -80px;
padding-bottom: 30px

}


/* -------------------------------SOCIAL-LINKS------------------------------------- */
.social-links ul {
display:inline;
padding-left: 150px;

}
.social-links li{
font-size: 100%;


}

.social-links li:hover,
.social-links li:active{
border-bottom: 2px solid #00a786;
transition: border-bottom 0.2s;
}



/* -------------------------------TOP-RIGHT------------------------------------- */
.top-right{
float:right;

}
.top-right {
float: right;
padding-bottom: 30px;
}


.top-right li {
font-size: 100%;
font-weight: 200;
}
.top-right li:hover,
.top-right li:active{
color:#005242;
transition: color 0.2s;
}


.top-right li:first-child{
border-left: 2px solid #fff;
border-width: thin;
}
.top-right li:last-child{
border-left: 2px solid #fff;
border-width: thin;
}
/* -------------------------------H1------------------------------------- */

.main-header{
padding-top: 30px;
padding-left: 130px;
float:left;

}
.header-text{
display: inline-block;
}

h1{
font-size: 90%;
color:#fff;
font-family: sans-serif;


}
span{
color:#00a786
}

/* -------------------------------MAIN-NAV------------------------------------ */
.main-nav{
float: right;
padding-right: 30px;
padding-top: 40px;
}
.main-nav-links{
display: inline-block;
}

.main-nav-links li:hover,
.main-nav-links li:active{
border-bottom: 2px solid #00a786;
transition: border-bottom 0.2s;

}
/* -------------------------------MAIN-SECTION------------------------------------ */
.main-section{




}
.main-content{
text-align: center;


}
.content{
padding-top: 50px;
color: #fff;
display:inline-block;
}
.content h2{

font-size: 100%;
}

.content p{
font-size: 60%
}

/* -------------------------------BUTTONS------------------------------------ */

.btn:link,
.btn:visited,
input[type=submit]{
display: inline-block;
padding :10px 30px;
margin-top: 60px;
font-size: 60%;
font-weight: 300;
text-decoration: none;
border-radius: 5px;

transition: background-color 0.2s,border 0.2s,color 0.2s;
msargin-right: 15px;
}

.btn-full:link,
.btn-full:visited,
input[type=submit]{
background-color: #00a786;
border: 1px solid #005242;
color: #fff;

}
.btn-full:hover,
.btn-full:active,
input[type=submit]{
background-color: #005242;
border: 1px solid #005242;
color: #fff;

}


.search-btn:link,
.search-btn:visited,
input[type=submit]{
display: inline-block;
padding :10px 30px;
margin-top: 60px;
font-size: 60%;
font-weight: 300;
text-decoration: none;
border-radius: 5px;

transition: background-color 0.2s,border 0.2s,color 0.2s;
msargin-right: 15px;
}

.search-btn:link,
.search-btn:visited,
input[type=submit]{
background-color: #00a786;
border: 1px solid #005242;
color: #fff;

}
.search-btn:hover,
.search-btn:active,
input[type=submit]{
background-color: #005242;
border: 1px solid #005242;
color: #fff;

}


/* -------------------------------form search------------------------------------ */
.section-Search{
background-color: #003027;
border: 2px solid #003027;
border-radius: 3px;
position:relative;
left:200px;
right:20px;
top: 500px;
height: 30vh;
width: 600px;
z-index: 99;

}
.main-Search{
padding:30px 10px;
display: inline;
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="vendors/css/normalize.css">
<link rel="stylesheet" type="text/css" href="vendors/css/grid.css">
<link rel="stylesheet" type="text/css" href="vendors/">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
<link href="https://fonts.googleapis.com/css?family=Lobster" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="css/styling.css">
<link rel="stylesheet" type="text/css" href="vendors/fonts/Aileron/">
<title>Williams Rental Propertie's</title>
</head>
<body>
<header>
<!--- TOP LEFT-------->
<div class="row">
<div class="top-left">
<ul>
<li> <i class="fas fa-phone-volume icon-contact ">(312)343-8748</i></li>
<li><i class="far fa-envelope icon-contact">WilliamsRentalProperties</i></li>
</ul>
</div>
<!--- SOCIAL LINKS-------->
<div class="social-links">
<ul>
<li><a href="#"><i class="fab fa-facebook-f"> </a></i></li>
<li><a href="#"><i class="fab fa-twitter"></i></a></li>
<li><a href="#"><i class="fab fa-instagram"></i></a></li>
<li><a href="#"><i class="fab fa-pinterest-square"></i></a></li>
<li><a href="#"><i class="fab fa-linkedin-in"></i></a></li>
</ul>
</div>
<!--- TOP RIGHT-------->
<div class="top-right">
<ul>
<li><i class="fas fa-user "> <a href="#"> Register</i></a></li>
<li> <i class="fas fa-sign-in-alt"><a href="#">Login</i></a></li>
</ul>
</div>
</div>
<!--- main Header-------->

<div class="main-header">
<div class="header-text">
<h1>Williams <span> Rental</span> Properties</h1>
</div>
</div>

<nav class="main-nav">
<div class="main-nav-links">
<ul>
<li> <a href="#"> Home</a></li>
<li> <a href="#"> Featured List</a></li>
<li> <a href="#"> About Us</a></li>
<li> <a href="#"> Pages</a></li>
<li> <a href="#"> Blog</a></li>
<li> <a href="#"> contact</a></li>
</ul>

</div>

</nav>

<section class="main-section">
<div class="main-content">
<div class="content">
<h2>Let Us Find You Your Dream Home!</h2>
<p>Search real estate property records, houses, condos, land and more .
Find property info from the most comprehensive source data.</p>
<a class="btn btn-full" href="#">View Details</a>
</div>
</div>
</section>
</header>

<section class ="section-Search">
<div class="main-Search">



<form class="Search" action="index.html" method="post">
<label for="address"></label>

<!--- city-------->

<input type="text" name="Search" placeholder="keyword,zipcode">

<!--- city-------->

<label for="city"></label>
<select class="city" name="city">
<option value="city">city</option>
</select>

<!--- state------->

<label for="state"></label>
<select class="state" name="state-form">
<option value="state">state</option>

<!--- search button------->
<a class="search-btn" href="#">Search</a>

</select>


</form>
</div>


</section>

</body>
</html>

最佳答案

你的按钮在里面<select>标签不正确。像这样将它移到外面,它应该会显示出来。

<!--- state------->

<label for="state"></label>
<select class="state" name="state-form">
<option value="state">state</option>
</select>

<!--- search button------->
<a class="search-btn" href="#">Search</a>

关于html - 按钮不会出现在网页中?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53490859/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com