“css中设置边框不显示,border:none; 和border:0; 都没用”的解决方案

我写了一个input,想让input出现这种效果:让input无边框

 可是我的边框就这样设置为border:none;或者border:0;都没效果。

 如图所示

 

 

我就试了一下,加上

background-image:transparent;
border:0;

设置背景透明,边框为0,结果就有效了

 成功:

 

 

原文地址:https://www.cnblogs.com/maleijiejie/p/13471020.html