gpt4 book ai didi

html - 如何在css3中水平对齐文本框,href

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

我想对齐文本框,2个href标签水平作为父div的全部内容显示。当我移动响应时,这种风格也希望保持不变。

<div class="filter_container" >
<input type="text" name="cusid" max-length="10" placeholder="Search Work Category" maxlength="10" id="search_wc" class="inp">
<a href="#" class="add_cate" onclick="add_activity(this);"><img src="images/add_so.png" title="Add Activity" rel="tooltip" /></a>
<a href="#" class="add_cate" onclick="add_category(this);"><img src="images/add_so.png" title="Add Workcategory" rel="tooltip" /></a>
</div>
/* css */
.filter_container{
display: block;
width: 90%;
margin: 5px auto;
text-align: left;
overflow: auto;
}
.add_cate{
display: inline-block;
vertical-align: middle;
text-align: right;
margin: 5px;
}
.inp {
font-size: 22px;
width: 80%;
float: left;
padding:5px 10px;
outline: none;
margin: 5px 0;
border: 1px solid white;
}

最佳答案

试试这段代码:

DEMO

CSS

img
{
width:100%;
}
.add_cate{
display: inline-block;
margin: 2%;
width: 46%;
float: left;
}

关于html - 如何在css3中水平对齐文本框,href,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21900339/

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