css怎么去掉輸入框樣式
本教程操作環境:windows10系統、CSS3&&HTML5版、Dell G3電腦。
css怎么去掉輸入框樣式
輸入框的默認樣式如下:
立即學習“前端免費學習筆記(深入)”;
想要去掉輸入框的樣式,只需要利用border-style屬性,去掉輸入框的樣式即可,當屬性的值設置為none時,會去掉輸入框的樣式,
border-style 屬性用于設置元素所有邊框的樣式,或者單獨地為各邊設置邊框樣式。示例如下:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> <style> input{ border-style:none; background-color:pink; } </style> </head> <body> 輸入框:<input type="text" value="默認值"> </body> </html>
輸出結果:
(學習視頻分享:css視頻教程)
以上就是css怎么去掉輸入框樣式的詳細內容,更多請關注有啊網站百科其它相關文章!
- 喜歡(10)
- 不喜歡(2)