开发者

edit box tinymce

I have created a simple website, now when I dubble click on my text on the website I wa开发者_开发技巧nt to show a 'tinymce box' that's able to edit my current text. Is that possible and how can I do that with javascript/jquery?


Check out TinyMCE's own documentation page, which is full of resources.

For example if you want to show a TinyMCE on button click, you need something like this:

http://tinymce.moxiecode.com/tryit/load_on_demand.php

First you might want to turn you div or whatever into a textarea, and then call the appropriate TinyMCE method.

Sorry for the not too detailed answer, but the question was not too detailed either...


Another easier solution might be to use functionylity that is there already. Seems like you are looking for the code plugin. On Click a box opens and the user can edit the html source of the editor content.

One of the optional buttons has 'html' written on it and can be used to go into HTML editing mode. You can see it in this full featured example - 6 places left of the top-right corner. In order to enable it on your own website you will need to add "code" to the list of plugins and "code" to the list of buttons.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜