我可以用 CSS 中的某些内容替换 maxlength 属性吗?
<input type='text' id="phone_extension" maxlength="4" />
No.
maxlength 用于行为。
CSS 是用于样式化的。
因此。