    // O2k7 skin (silver)
    tinyMCE.init({
        // General options
        /*mode : "textareas",*/
        mode : "exact",
        elements : "texto",
        theme : "advanced",
        skin : "default",
        /*skin_variant : "black",*/
        plugins : "safari,pagebreak,style,advimage,advlink,preview,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,inlinepopups",

        // Theme options
        theme_advanced_buttons1 : "cut,copy,paste,|,undo,redo,|,justifyleft,justifycenter,justifyright,justifyfull",
        theme_advanced_buttons2 : "bold,italic,underline,|,forecolor,backcolor,|,link,unlink,code,|,fullscreen",
        theme_advanced_buttons3 : "",
        theme_advanced_buttons4 : "",
        theme_advanced_toolbar_location : "top",
        theme_advanced_toolbar_align : "left",
        theme_advanced_statusbar_location : "bottom",
        theme_advanced_resizing : true,
        convert_urls : false,

        // Drop lists for link/image/media/template dialogs
        template_external_list_url : "lists/template_list.js",
        external_link_list_url : "lists/link_list.js",
        external_image_list_url : "lists/image_list.js",
        media_external_list_url : "lists/media_list.js",
        // Replace values for the template plugin
        template_replace_values : {
            username : "",
            staffid : ""
        },
        translate_mode : true,
        language : "pt"
    });
    function toggleEditor(id) {
        if (!tinyMCE.get(id))
            tinyMCE.execCommand('mceAddControl', false, id);
        else
            tinyMCE.execCommand('mceRemoveControl', false, id);
    }

    function brstonewline(element_id, html, body) {
        html=html.replace(/<br\s*\/>/gi, '\n');
        return html;
    }

    function insertHTML(html) {
        /*alert(html);*/
        /*parent.tinyMCE.execCommand('mceInsertContent',false,'teste')*/
        parent.tinyMCE.execCommand('mceInsertContent',false, html);
    }