<?php

$wysiwyg_editor_html .= '<link rel="stylesheet" type="text/css" href="'.BINGOTOPURL.'/js/yuieditor/build/fonts/fonts-min.css" />';
$wysiwyg_editor_html .= '<link rel="stylesheet" type="text/css" href="'.BINGOTOPURL.'/js/yuieditor/build/editor/assets/skins/sam/simpleeditor.css" />';
$wysiwyg_editor_html .= '<script type="text/javascript" src="'.BINGOTOPURL.'/js/yuieditor/build/yahoo-dom-event/yahoo-dom-event.js"></script>';
$wysiwyg_editor_html .= '<script type="text/javascript" src="'.BINGOTOPURL.'/js/yuieditor/build/element/element-beta-min.js"></script>';
$wysiwyg_editor_html .= '<script type="text/javascript" src="'.BINGOTOPURL.'/js/yuieditor/build/container/container_core-min.js"></script>';
$wysiwyg_editor_html .= '<script type="text/javascript" src="'.BINGOTOPURL.'/js/yuieditor/build/editor/simpleeditor-beta-min.js"></script>';

$wysiwyg_editor_html .= <<<EOD
<script type="text/javascript">
<!--
YAHOO.util.Event.addListener(window, "load", yuieditor);
function yuieditor() {
    var Dom = YAHOO.util.Dom,
        Event = YAHOO.util.Event;
    
    var myConfig = {
        height: '200px',
        width: '100%',
        dompath: true,
		handleSubmit: true,
        focusAtStart: false
    };

    YAHOO.log('Create the Editor..', 'info', 'example');

	var obj = this.document.getElementsByTagName('textarea');
	for(var i=0;i<obj.length;i++) {
		$('unitContainerMain').className += " yui-skin-sam";
		var myEditor = new YAHOO.widget.SimpleEditor($(obj[i]).id, myConfig);
   		myEditor.render();
	}
};
-->
</script>
EOD;
?>