def get_html_text_editor(<EOL>name,<EOL>id=None,<EOL>content='<STR_LIT>',<EOL>textual_content=None,<EOL>width='<STR_LIT>',<EOL>height='<STR_LIT>',<EOL>enabled=True,<EOL>file_upload_url=None,<EOL>toolbar_set="<STR_LIT>",<EOL>custom_configurations_path='<STR_LIT>',<EOL>ln=None):
ln = default_ln(ln)<EOL>if textual_content is None:<EOL><INDENT>textual_content = content<EOL><DEDENT>editor = '<STR_LIT>'<EOL>if enabled and ckeditor_available:<EOL><INDENT>file_upload_script = '<STR_LIT>'<EOL>if file_upload_url is not None:<EOL><INDENT>file_upload_script = '''<STR_LIT>''' % {'<STR_LIT>': file_upload_url}<EOL><DEDENT>editor += '''<STR_LIT>''' %{'<STR_LIT>': cgi.escape(textual_content),<EOL>'<STR_LIT>': content,<EOL>'<STR_LIT:width>': width,<EOL>'<STR_LIT>': height,<EOL>'<STR_LIT:name>': name,<EOL>'<STR_LIT:id>': id or name,<EOL>'<STR_LIT>': custom_configurations_path,<EOL>'<STR_LIT>': toolbar_set,<EOL>'<STR_LIT>': file_upload_script,<EOL>'<STR_LIT>': cfg['<STR_LIT>'],<EOL>'<STR_LIT>': ln}<EOL><DEDENT>else:<EOL><INDENT>textarea = '<STR_LIT>'% {'<STR_LIT:content>': cgi.escape(textual_content),<EOL>'<STR_LIT:width>': width,<EOL>'<STR_LIT>': height,<EOL>'<STR_LIT:name>': name,<EOL>'<STR_LIT:id>': id and ('<STR_LIT>' % id) or '<STR_LIT>'}<EOL>editor += textarea<EOL>editor += '<STR_LIT>'<EOL><DEDENT>return editor<EOL>
Returns a wysiwyg editor (CKEditor) to embed in html pages.

Fall back to a simple textarea when the library is not installed,
or when the user's browser is not compatible with the editor, or
when 'enable' is False, or when javascript is not enabled.

NOTE that the output also contains a hidden field named
'editor_type' that contains the kind of editor used, 'textarea' or
'ckeditor'.

Based on 'editor_type' you might want to take different actions,
like replace CRLF with <br/> when editor_type equals to
'textarea', but not when editor_type equals to 'ckeditor'.

@param name: *str* the name attribute of the returned editor

@param id: *str* the id attribute of the returned editor (when
    applicable)

@param content: *str* the default content of the editor.

@param textual_content: *str* a content formatted for the case where the
    wysiwyg editor is not available for user. When not
    specified, use value of 'content'

@param width: *str* width of the editor in an html compatible unit:
    Eg: '400px', '50%'.

@param height: *str* height of the editor in an html compatible unit:
    Eg: '400px', '50%'.

@param enabled: *bool* if the wysiwyg editor is return (True) or if a
    simple texteara is returned (False)

@param file_upload_url: *str* the URL used to upload new files via the
    editor upload panel. You have to implement the
    handler for your own use. The URL handler will get
    form variables 'File' as POST for the uploaded file,
    and 'Type' as GET for the type of file ('file',
    'image', 'flash', 'media')
    When value is not given, the file upload is disabled.

@param toolbar_set: *str* the name of the toolbar layout to
    use. CKeditor comes by default with 'Basic' and
    'Default'. To define other sets, customize the
    config file in
    /opt/cds-invenio/var/www/ckeditor/invenio-ckconfig.js

@param custom_configurations_path: *str* value for the CKeditor config
    variable 'CustomConfigurationsPath',
    which allows to specify the path of a
    file that contains a custom configuration
    for the editor. The path is relative to
    /opt/invenio/var/www/

@return: the HTML markup of the editor