views:

462

answers:

1

hi,

is there a way to add tinymce into my own wordpress plugin? i've got a textarea in my backend script and want to make this area into a tinymce wysiwyg editable field.

is there a way to do that?

wysiwyg

edit

<?php
    wp_tiny_mce(false,array("editor_selector" => "test"));
?>
<textarea class="test" id="test" name="test"></textarea>

does not work for me

js error is like mceerror

also

<textarea class="theEditor" id="videogalerie-add_description" name="videogalerie-add_description"></textarea> did not work
A: 

Ok, so this post didn't seem to help you. I played around with it some and got it working by adding those following class to the textarea: class="theEditor"

hsatterwhite
does not work for me. see my edit
choise
Have you tried using a different id/class in the TinyMCE JS and on the textarea markup itself?
hsatterwhite
Try it now and see if it works.
hsatterwhite
also, no luck. hm...strange. just adding "theEditor" ? see my edit how i tryed it.
choise
Shame to hear it didn't work, but yes all I did was add the class of theEditor.
hsatterwhite
the wp version is "WordPress 2.7". probably thats the reason? cannot update to a newer version
choise
Ahhh ok, well you could try to do this. View the source and see if the visual editor is using a different class name? Outside of that I'm not too sure since I can't access a test WP install at this time. My apologies if this has been more of a run around than helpful.
hsatterwhite
no class in there http://dl.getdropbox.com/u/6357394/editorclass.png . huh, quite bad.
choise
Try adding the class mceEditor to it.
hsatterwhite
i'll give it a try tomorrow ;)
choise
nope, no luck at all
choise
Damn.. I'm going to do some more digging for version 2.7
hsatterwhite
i'll accept your answer. it does not work for me, but i think it works with the latest versions of WP. ;)
choise
Thanks, but that's a damn shame. I haven't found anything regarding version 2.7, but yea it works in 2.9.x
hsatterwhite