[whatwg] Simple solution for select editable

Matthew Raymond mattraymond at earthlink.net
Tue Jun 29 06:37:41 PDT 2004

    I've come up with a simple solution that allows <select editable> to 
degrade gracefully in Web Forms 2.0. Just put the extra text box in a 
repetition template that has zero instances:

<select editable="editable" name="thing">
<span repeat="template" repeat-start="0">
   or you can type a new entry: <input type="text" name="thing_new">

    In non-WF2 user agents, "editable" is ignored and the <span> is 
rendered, allowing the user to put a custom entry in the text box. In a 
WF2 UA, only the <select> is shown, but it's rendered as a combo box. 
(Finally something good comes out of this stupid template defect!)

More information about the whatwg mailing list