问题
This question already has an answer here:
- Insert text into textarea with jQuery 17 answers
How can i utilize jQuery to insert text at the cursor into a textarea.
回答1:
There is a plug-in that can get the cursor's position within a text area. This could be utilized to insert text at that designated position.
来源:https://stackoverflow.com/questions/1882890/jquery-insert-text-to-textarea