Currrently i created new plugin for adding the new button In tool bar. now i am able to add new button in CKEditor.
if you will observe bold, italic button functionality then you will find that if i will select some text and then click on bold button then bold tag will come surround the text and if again i will select same text and again i will click on same button then that tag will removed from source.
so same functionality i want to implement in my case. currently i am able to add tag surrounding the text area but not able to remove..
so i want to add same bold type functionality in my case.. so please some one suggest me. how to add this functionality and what should i do for adding this functionality?????
i am creating button for <no-Lexicon></no-Lexicon> tag.
You should check a plugin's
You should check a plugin's source to see how it's done. In the case of basicstyles, it's CKEDITOR.styleCommand that handles it. Tracking it down will lead you to core/styles, which leads you to removeStyle, etc. You'll have to do some digging.
Customer and Community Manager, CKSource
Follow us on: Facebook, Twitter, LinkedIn
If you think you found a bug in CKEditor, read this!