HTML:
<form method = "POST" > <h1>Soccer Shoes Finder</h1> <div ></div> <div > <input name = "name" type="text" placeholder="name"/> <input name = "size" type="text" placeholder="Size"/> <button aria-hIDden="true"></button> </div></form>
元素的CSS:
input[name="size"]{ wIDth: 50%;}
这是一个更好的上下文的codepen:
http://codepen.io/tadm123/pen/ZLVWpd
解决方法 我建议使用这种方法.<form method="POST"> <h1 >Soccer Shoes Finder</h1> <div ></div> <div > <div > <div > <input name="name" type="text" placeholder="name" /> </div> <div > <input name="size" type="text" placeholder="Size" /></div> <div > <button aria-hIDden="true"><i ></i></button></div> </div> </div></form>
更新的Codepen:
http://codepen.io/hunzaboy/pen/aJJpMK
以上是内存溢出为你收集整理的html – CSS-更改搜索框的宽度全部内容,希望文章能够帮你解决html – CSS-更改搜索框的宽度所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)