When the button is pressed, you can simply read the selected option using jQuery and add it to the text area.
HTML
<select id="selectBox"> <option>option 1</option> <option>option 2</option> <option>option 3</option> </select> <input id="copyBtn" type="button" value="copy" /> <textarea id="output"> This is some intro text </textarea>
JQuery
$("#copyBtn").click(function(){ var selected = $("#selectBox").val(); $("#output").append("\n * " + selected); });
You can add text to the text field, it does not display html tags (so the list inside it will not work). I used \n to create new lines.
Fiddle
Here is a working fiddle
source share