CSS submit button weird rendering on iPad/iPhone

拥有回忆 提交于 2019-11-26 12:34:36

问题


I noticed that if I style my buttons with CSS using radius, colors and borders, they look good but in the iphone/ipad/ipod they look terrible...shouldn\'t be the same rendering as in Safari Desktop??

\"enter


回答1:


oops! just found myself: just add this line on any element you need

   -webkit-appearance: none;



回答2:


Add this code into the css file:

input {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}

This will help.




回答3:


The above answer for webkit appearance did the magic, but the button still looked kind pale/dull compared to the browser on other devices/desktop. I also had to set opacity to full (ranges from 0 to 1)

-webkit-appearance:none;
opactiy: 1

After setting the opacity, the button looked the same on all the different devices/emulator/desktop.



来源:https://stackoverflow.com/questions/5438567/css-submit-button-weird-rendering-on-ipad-iphone

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!