浏览器的“建议列表”如何显示作品?
许多网站使用 元素从客户那里获取简单的文本数据。您可以将浏览器配置为记住您在这些字段中输入的值,以便它可以建议您支持值列表,从而加快您的数据输入体验。
但是,我看到了奇怪的行为。在相同类型的某些字段上,浏览器不建议任何内容,或者建议与其他字段不同的列表。我检查了所有字段,所有字段都具有相同的 类型。
有谁知道浏览器如何区分同一 HTML 表单控件的不同列表(或无列表)?
Many websites use <input type='text'>
element to get simple text data from their customers. You can configure your browser to remember the values you enter into these fields, so that it can suggest you back a list of values, to speed up your data entry experience.
However, I'm seeing a strange behavior. On some fields of the same type, browser doesn't suggest anything, or suggests a different list from other fields. I've checked all fields and all of them are of the same <input type='text'>
type.
Does anybody know how browser differentiates between different lists (or no list) for the same HTML form control?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
表单元素上有一个属性,允许它们在语义上指定其预期内容(我相信它是 V_Card 属性)。
下页给出了简要说明和可接受值的表:
http://microformats.org/wiki/hcard-input-formats
There's an attribute on form elements that allows them to semantically specify their intended content (I believe its the V_Card attribute).
The following page gives a brief explanation and a table of acceptable values:
http://microformats.org/wiki/hcard-input-formats