In my project, we are using bootstrap-wysihtml editor for rich text editing. I initialize the editor using following code,
$(document).ready(function(){
$('#messageText').wysihtml5();
})
I need to add a custom button to the editor, which works similar to insertLink, but would allow user to enter only text for the link and the link will be inserted by application for the user.
Any help is highly appreciated.
Since I could not figure out a straight forward way, I did the following to get it done,
One of the challenge I come across was, need to insert the html at the current cursor position, I could have used a javascript function to achieve it, but I preferred the following and it works great so far :)
If anyone knows a better way of doing, let me know...