【发布时间】:2014-12-02 19:51:42
【问题描述】:
我正在为我的网站创建一个表单,并为我的代码的输入消息部分提供以下代码。我只想更改此输入框的高度,但不确定如何操作。 如果可能的话,我宁愿更改 html 代码中的高度而不是 CSS。 谢谢:)
<p>
<label for="from">Your message:</label>
<br />
<input type="text" name="message" id="message" value="type your message..." maxlength="40" size="40" onclick="this.value=''"/>
</p>
我已经尝试过:
<p>
<label for="from">Your message:</label>
<br />
<input type="text" name="message" id="message" value="type your message..." maxlength="40" width="40px" height="40px" onclick="this.value=''"/>
</p>
但这没有用
【问题讨论】:
-
您可以添加:
style="height: 40px;". -
谢谢你,我现在可以工作了 :)
-
很高兴听到这个消息,不客气!
标签: html css forms input height