开发者

Button re sizing on a webpage

开发者 https://www.devze.com 2023-03-26 21:41 出处:网络
I programmed a simple html page with some buttons on them that I made large using the html command <input type=\"button\" style=\"height: 50px; width: 100px\" value=\"button\" />

I programmed a simple html page with some buttons on them that I made large using the html command

<input type="button" style="height: 50px; width: 100px" value="button" />

This works OK on my win7 / google chrome / IE 8 platform, but when I passed a copy of the html file to a friend with a macbook / safari setup the buttons were not any different from normal html b开发者_StackOverflowuttons.

I read online that the buttons are rendered more by the OS than by the browser and this probably explains the difference. My question then is being that I do not have a non-windows machine to test on, will the buttons be the same on all platforms if I do the styling in CSS?


That is the expected behaviour, Andy.

If you set items such as the border-style or background of a button, you will be overriding the browser's default button styling (which for many browsers, by default, is the host OS style), and so you'll see something like Facebook's or StackOverflow's buttons that are platform independent..

0

精彩评论

暂无评论...
验证码 换一张
取 消