Answer the question
In order to leave comments, you need to log in
Helper script to write code in textarea in html and css?
Desktop text editors have a great automatic tag completion feature. For example, I type <p> on the keyboard , and the editor turns it into <p></p> , and puts the cursor between the tags.
I want to find a script that could do the same when I write in a textarea on a website. I'm not a programmer at all, but I suspect that this can be done by this plugin for jQuery.
I draw your attention to the fact that I am looking for a script for TEXTAREA without SUGGEST , i.e. without offering possible options, it is necessary for the script to substitute its guess instead of what I wrote without asking. (For inputs with a hint in Google, there are a lot of options, this is not it).
And I'm definitely not looking for a WYSIWYG editor.
Answer the question
In order to leave comments, you need to log in
There is a jQuery plugin for this purpose: fieldSelection .
Specifies the position of the cursor in input text and textarea.
To help with the implementation I will say:
With this library, you have to check the text to the left of the cursor and replace it when it matches a regular expression.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question