- From: Andrea Rendine <master.skywalker.88@gmail.com>
- Date: Fri, 7 Oct 2016 12:40:59 +0200
- To: "Jukka K. Korpela" <jukka.k.korpela@kolumbus.fi>
- Cc: "public-html@w3.org LIST" <public-html@w3.org>
- Message-ID: <CAGxST9k10WcEmLRV0Wvx4Heo93_Pf-iK-EPk=cuBF-GO6G71nQ@mail.gmail.com>
It means for example `<input type=text multiple name="tags[]" /> insert the tags for this article`, a control present in several websites. Basically I had this idea because of `<datalist>`. I had to implement a custom js way to show the suggestion box multiple times for something similar to a tag system (it's not a production web app so I didn't want anything too complicated). This feature exists in real world and allows to insert multiple tags, possibly picking them from a suggestion list, when the author doesn't know in advance whether strings will belong to the list, nor how many strings will be inserted. If implementers are interested in adopting a native system for a widespread feature, I guess there are three possible ways to do that: - implement `multiple` in text input and capture each value separately (e.g. when user presses enter); - implement `datalist` on textarea, stating that suggestions are to be shown on newline; - allow authors to indicate a separator character, which also makes suggestions appear again. Then it's up to the author to handle the input concatenation, in a way similar to email fields (but unlike email, you cannot state in advance which character the input splits on). In light of the extension of datalist, my favourite alternative is the second, of course, because it's the most natural: newline is a perfect separator character and it doesn't need explanations to the user, control value is easy to scroll and edit, and this feature would provide no exotic interface on an established element as an <input type=text multiple> field would. But I was curious whether or not this feature had ever been discussed.
Received on Friday, 7 October 2016 10:41:27 UTC