Home >Web Front-end >JS Tutorial >Get the cursor position of div edit box, textarea, input text. Introduction to methods compatible with IE, FF and Chrome_javascript skills
After 2 hours of searching online, none of them are compatible with FF. It seems that this kind of thing is not readily available online, so I have to make it myself.
Now that it is released, it will be available online for people to use in the future.
In order to save trouble, jquery is used in a few places. It is also very convenient to modify the native JS. If you need it, please modify it yourself.
Everyone is welcome to pass by the expert to make a decision, and you are welcome to leave a message to provide improved code.
It has been improved and compatible with Chrome. The following code has been modified to the latest version
The source code is available