chrome下input[type=text]的placeholder不垂直居中的问题解决


http://blog.csdn.net/do_it__/article/details/6789699

 

<input type="text" placeholder="search word" name="p" />

 

但是在chrome下显示的search word并不能垂直居中。

 

后来找了很久终于在stackoverflow上找到了对应的方法。

参考:http://stackoverflow.com/questions/4919680/html5-placeholder-css-padding-problem

就是一句:把line-height设置为normal

 

line-height: normal; /* for non-ie */
line-height: 22px\9; /* for ie */


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM