所以我很擅长CSS并且在CSS存在之前没有做太多的HTML ...所以我正在努力学习......我已经搜索并尝试了几件事来让它工作但没有任何效果。 ..我希望我的“搜索”框在表头中垂直居中。我该如何实现这一目标?我已经尝试了我在这个网站上阅读的保证金设置和其他建议,所以我假设我做错了什么我看不到。希望你能帮忙......我需要具体的指示,比如在页面上放置代码。谢谢你的帮助!这就是我所拥有的。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Have A Voice - Speak Up!</title>
<style type="text/css">
body{
margin-top:0px;
padding-top:0px;
margin-left:0px;
padding-left:0px;
margin-right:0px;
padding-right:0px;
margin-bottom:15px;
padding-bottom:0px;
border-spacing;0px;
space:0px;
vertical-align:middle;
padding: 0;
}
#my_input {
height;100%;
}
#my_table {
table-layout:fixed;
}
#search{
border:red solid 1px;
height:50px;
display:table-cell;
width:100%;
vertical-align:top
}
</style>
</head>
<body bgcolor="#b2b2b2">
<table width=100% height=706 border="0" cellpadding="0" cellspacing="0">
<tr>
<td height="50" align="center" nowrap="nowrap" background="Images/LeftHeader2.png"> </td>
<td background="Images/HeaderCenter2.png" colspan="3" height="50" align="leftr"><a href="index.html"><img src="Images/HaveAVoiceLogo.png" height="50" border="0"/></a> <input type="search" placeholder="Search" results="0" border="0" /></td>
<td height="50" align="center" background="Images/LeftHeader2.png"> </td>
</tr>
<tr>
<td width="5%" rowspan="3" align="center" nowrap="nowrap"> </td>
<td width="10%" rowspan="3" align="center">Menu</td>
<td width="80%"height="450" colspan="2" align="center">Video Frame</td>
<td width="5%" rowspan="3" align="center"></td>
</tr>
<tr>
<td height="50" align="center">Like Vote Rate</td>
<td width="10%" rowspan="2" align="center"><p>More</p>
Videos</td>
</tr>
<tr>
<td height="250" align="center">Comment</td>
</tr>
<tr>
<td height="50" colspan="5" align="center" nowrap="nowrap">Footer</td>
</tr>
</table>
</body>
</html>