How to add TinyMCE to a textarea created in CustomPress

In response to a request on this post here is a plugin I created to add TinyMCE to a textarea created in CustomPress:

I have pasted the whole code below. To make it work, simply paste in the field ID in place of my field ID "_ct_textarea_4fd2000002023". You can also add as many as you want to the code.

How does it work? I use jquery to find the textarea to then add the class "theEditor", the extra javascript then does the TinyMCE magic. Thats pretty much it. I am sure with a bit of coding someone could wrap an admin panel around this allowing you to add multiple fields from within the admin.

Be sure to check out the screenshots... and yes I am a bit proud right now.

<?php
/*
Plugin Name: TinyMCE to textbox
Description: Adds TinyMCE to a named textbox
Version: 1.0
Author: Lee Jackson
Author Site: http://www.elliottyoung.co.uk

*/

// Main resource - http://allcreatives.net/2011/02/02/using-the-native-wordpress-tinymce-wysiwyg-editor-with-your-custom-post-meta-textareas/

function tinymce_to_named_textarea() {
    ?>

<script type=&quot;text/javascript&quot;>
                /* <![CDATA[ */
 		jQuery('#_ct_textarea_4fd2000002023').addClass('theEditor')
                jQuery(document).ready( function () {
                    if ( typeof( tinyMCE ) == &quot;object&quot; && typeof( tinyMCE.execCommand ) == &quot;function&quot; ) {

                        tinyMCE.execCommand(&quot;mceAddControl&quot;, true, &quot;_ct_textarea_4fd20000402023&quot;);

                    }
                });

                /* ]]> */
        </script>

<?php
}
// Add hook for admin <head></head>
add_action('admin_head', 'tinymce_to_named_textarea');

?>