[wp-hackers] Second editor instance
Alex Günsche
ag.ml2008 at zirona.com
Thu Mar 20 09:59:40 GMT 2008
On Thu, 2008-03-20 at 01:41 -0800, Andrew Ozz wrote:
> I think if you call the_editor() more than once on the same page, it
> will insert tags with the same IDs, so the js will get confused.
>
> Perhaps append another textarea on the page and add a button to bind
> TinyMCE to it too, or you can make it bind on page load. Then you will
> have 2 editors that look the same, but save to 2 different textareas.
>
> If you want them to be different, start the second one with another init
> array. See the documentation here:
> http://wiki.moxiecode.com/index.php/TinyMCE:Index
Thanks for your suggestions.
As for the instance, I would expect that the_editor() creates an
independent instance, as it explicitly asks for the id for the textarea
(second parameter), and based on that, it should be possible to create
an independent "namespace". It just seems that some features are
hardcoded to the default instance, such as the switcher between visual
and HTML mode.
Kind regards,
Alex
--
Alex Günsche, Zirona OpenSource-Consulting
Blogs: http://www.zirona.com/ | http://www.regularimpressions.net
*** Want to test the shiny new release of InstantUpgrade? ***
http://www.zirona.com/blog/software/instantupgrade-10-beta/
More information about the wp-hackers
mailing list