inungh Posted September 20, 2013 Share Posted September 20, 2013 I have a select control on the form and woudl like to let user add new record if the value does not exist in the list. I do not find any property for this, users must select from the list.Can you please advise if there is any way to do so?Your information and help is great appreciated,Regards,Iccsi, Link to comment Share on other sites More sharing options...
niche Posted September 20, 2013 Share Posted September 20, 2013 Please post your code (with the code tags) so we can see specifically what you're talking about. Link to comment Share on other sites More sharing options...
inungh Posted September 21, 2013 Author Share Posted September 21, 2013 <select> <option value="volvo">Volvo</option> <option value="saab">Saab</option> <option value="mercedes">Mercedes</option> <option value="audi">Audi</option> </select> Thanks for the information and help, I have above code and have this select control on the form. It only allows user to enter option value in the list, I would like user to enter a new list like 'BMW', 'Toyota' if it is missing from the list. Thanks again for helping, Regards, Iccsi, Link to comment Share on other sites More sharing options...
thescientist Posted October 2, 2013 Share Posted October 2, 2013 You won't be able to do this with just HTML. If you want people to add to the list on the fly, you will need Javascript. If you need them to be able to save and persist this data after a user has made one, you will need Javascript, PHP, and some sort of storage method, like a file or database. I would recommend you start reviewing the PHP and PHP forms chapters of the w3schools tutorials. Link to comment Share on other sites More sharing options...
davej Posted October 2, 2013 Share Posted October 2, 2013 Maybe you could tolerate something like this... <select> <option value="volvo">Volvo</option> <option value="saab">Saab</option> <option value="mercedes">Mercedes</option> <option value="audi">Audi</option> <option value="other">Other</option></select><br/><label>Other:<input type="text" name="other"/></label> Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now