I have a text_field of id #image_tag_list_tokens and the textfield appears as follows in the image form:
= f.text_area :tag_list_tokens, label: "Tags (optional) ->", data: {load: @image_tags }, label: "Tags"
I have an input field and a button as follows:
<input type="text" name="myNewTag" id="my_new_tag">
<button name="meNewTagButton" type="button" id="createMy_new_tag">Create new tag</button>
When the user types in the input field a new tag, I want to grab that new tag and add it inside the text area of :tag_list_tokens without reloading the page. The value of the tag_list_tokens textfield is of the following format :
"old_tag1,old_tag2,'new_tag1','new_tag2'"