gpt4 book ai didi

html - 将 <input> 格式从 HTML 更改为 CSS

转载 作者:太空宇宙 更新时间:2023-11-04 05:16:14 24 4
gpt4 key购买 nike

我想知道如何从 html 格式的标签转到 CSS。 HTML 是

Ball: <input type=text name=BL size=5 value=5>

我目前拥有的 CSS 是:

#info input[type=text]{}

我的目标是尽可能少的 html。谢谢:)

最佳答案

不完全确定你的目标是什么,但你可以这样设置:

<input type="text" class="inputfield" name="BL" size="5" value="5" />

并用 CSS 控制它:

.inputfield {
border: 1px solid #000;
font-family: Tahoma, Verdana, sans-serif;
color: #ff0000;
background: #c3c3c3;
}

关于html - 将 &lt;input&gt; 格式从 HTML 更改为 CSS,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7989834/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com