Zum Inhalt springen

RTE im eigenen BE Modul

Erstellt am 5. Oktober 2006 · 19 Antworten · letzte Antwort am 25. Januar 2008

Tags: Frage

fritze3001 ·

ich habe über den kickstarter ein neues modul angelegt. in der typo3conf/ext wurde auch alles brav erstellt.

wie kann ich jetzt in meinem modul mod1/index.php ein textfeld anlegen (in der function moduleContent), das mir die funktionen des RTE bietet? kennt einer einen link oder könnte mir jemand einen rat geben, wie ich eine entsprechende vorlage bekomme?

vielen dank und viele grüße

:-)

fritze3001 ·

mhmm d.h. das ich den RTE nachbauen muss, der dann aber unabhängig von den restlichen RTE einstellungen zu benutzen ist. schade, aber wenns nicht anders geht :-(

steffenk ·

Du kannst Dir ja mal die alt_doc.php anschauen, die Typo3 zum bearbeiten von Datensätzen nutzt - da ist auch ein rte drin. Vielleicht wirst Du ja fündig.

steffenk ·

auf das Nievau begeb ich mich nicht 😉

Hier ist mal ein Beispiel, die Vars müssen halt entsprechen gesetzt werden:

$RTEsetup = $GLOBALS['BE_USER']->getTSConfig('RTE',t3lib_BEfunc::getPagesTSconfig($tscPID));
$RTEtypeVal = t3lib_BEfunc::getTCAtypeValue($table,$row);
$thisConfig = t3lib_BEfunc::RTEsetup($RTEsetup['properties'],$table,$field,$RTEtypeVal);
$RTEobj = &t3lib_BEfunc::RTEgetObj();
$content = $RTEobj->drawRTE($this,$table,$field,$row,$PA,$specConf,$thisConfig,$RTEtypeVal,$RTErelPath,$thePidValue);
fritze3001 ·

ich bekomme bei dem beipsiel code nur ein einfaches textfeld ohne editierfunktionen :-/ hat denn keiner ein erweitertes beispiel (vielleicht sogar einen vollständigen dummy) ???

Spyro ·

und hoch damit 🙂

Bin atm auch an der Sache dran den HTMLArea RTE in eine BE-Ext. zu integrieren. Hat sich bei dir in der Hinsicht etwas ergeben, das brauchbar wäre?

Ich bin bisher genauso weit, wie du gekommen.
Mein bisheriges Verständnis reicht zumindest mal so weit(In Bezug auf steffenks Beitrag):

$RTEsetup: Die aktuelle RTE-Konfiguration der Seite $tscPID. Wenn ich hier $tscPID durch $this->id ersetzte bekomme ich also immer die RTE-Konfiguration der aktuellen Seite.

$RTEtypeVal: Ich hab zwar verstanden, dass hier eine Typeninformation(weis leider nicht wozu) aus der $TCA geholt wird, mehr leider auch nicht.

$thisConfig: Ich nehme an, dass dies die Konfiguration des RTEs ist, welche benutzt werden soll. Sollte das stimmen, entsprechen $table und $field doch der Angabe, woher er diese bezieht, oder? Hier müsste ich also die Rootseite angeben, in der die RTE-Confs im TSConfig eingetragen sind?

$RTEobj: Ist eine Instanz der tx_htmlarea_base?

zu drawRTE:
$this muss bei mir eine Instanz von TCEForms sein, damit er überhaupt etwas ausgibt.
$table, $field und $row beschreiben, nehme ich an, das Feld in der DB, von welchem der Inhalt genommen wird.
$PA sind zusätzliche Konfigurationen, aber ich habe leider keinen blassen Schimmer, was für welche o.O
$specConf dito.
$RTErelPath ist der relative Pfad zum speichern von Bildern u.ä.
$thePidValue ist, glaube ich, die Seite, auf der wir uns gerade befinden.

Soviel zu meinem aktuellen Verständnis, das leider sehr beschränkt ausfällt 🙁 Aber ich geb mir Mühe, den Code zu verstehen 🙂

Gruß,
Spyro

EDIT:
Hab meine Arbeit inzwischen auf den tinyRTE umgestellt. Ist um einiges einfacher der kleine 🙂 Problem des Verständnises bleibt aber nach wie vor das Gleiche.

Spyro ·

Ich schreib mal noch ein bisschen was dazu. Vielleicht gibt es ja doch jemanden unter uns, der weiterhelfen kann 🙂

Bisher bin ich soweit, dass ich mit folgendem Code, die onfiguration einigermaßen hinbekomme, jedoch immer noch kein Editor geladen wird. Stattdessen sieht man nur ein Textfeld.

	// Get the variables needed.
							$thePidValue = $this->id;
							$RTEtypeVal = 'text';
							$RTErelPath = '';
							$table = $this->elementsDBTable;
							$field = 'rtecontent';
							$uid = 3;
							$row = t3lib_BEfunc::getRecord($table,$uid,'*','');
						
								// Create the $PA[]-Array.
							t3lib_div::loadTCA($table);
							$PA = array(
								'altName'		=> '',
								'palette'		=> 0,
								'extra'			=> "richtext:rte_transform[flag=rte_enabled|mode=ts_css]",
								'pal'			=> '9',
								'fieldConf'		=> $TCA[$table]['columns'][$field],
								'fieldTSConfig'		=> '',
								'itemFormElName'	=> '',
								'itemFormElName_file'	=> '',
								'itemFormElValue'	=> '',
								'itemFormElID'		=> '',
								'onFocus'		=> '',
								'label'			=> '',
								'fieldChangeFunc'	=> array(
									'TBE_EDITOR_fieldChanged'	=> "TBE_EDITOR.fieldChanged('".$table."','".$thePidValue."','bodytext','data[".$table."][".$thePidValue."][bodytext]');",
									'alert'				=> ''
								)
							);
							
								// Customize the Array.
							unset($PA['fieldConf']['exclude']);
							
							$PA['fieldConf']['l10n_mode']	= 'prefixLangTitle';
							$PA['fieldConf']['l10n_cat']	= 'text';
							$PA['fieldConf']['label']	= 'LLL:EXT:lang/locallang_general.php:LGL.text';
							
							$PA['fieldConf']['config']['wizards']['_PADDING']	= 4;
							$PA['fieldConf']['config']['wizards']['RTE']['icon']	= "../../../../typo3/wizard_rte2.gif";
							$PA['fieldConf']['config']['wizards']['RTE']['script']	= "../../../../typo3/wizard_rte.php";
							$PA['fieldConf']['config']['wizards']['table']	= array(
													'notNewRecords'		=> 1,
													'enableByTypeConfig'	=> 1,
													'type'			=> 'script',
													'title'			=> 'Table wizard',
													'icon'			=> "../../../../typo3/wizard_table.gif",
													'script'		=> "../../../../typo3/wizard_table.php",
													'params'		=> array(
																	xmlOutput	=> 0
																)
												);
							$PA['fieldConf']['config']['wizards']['forms']	= array(
													'notNewRecords'		=> 1,
													'enableByTypeConfig'	=> 1,
													'type'			=> 'script',
													'title'			=> 'Forms wizard',
													'icon'			=> "../../../../typo3/wizard_forms.gif",
													'script'		=> "../../../../typo3/wizard_forms.php",
													'params'		=> array(
																	xmlOutput	=> 0
																)
												);
							$PA['fieldConf']['config']['softref']	= 'typolink_tag,images,email[subst],url';
							$PA['fieldConf']['config']['form_type']= 'text';
							
							
								// Create the special configuration.
							$specConf = array(
								'richtext'	=> 1,
								'rte_transform'	=> array(
									'parameters'	=> array(
										'flag=rte_enabled',
										'mode=ts_css'
									)
								)
							);
							
							
								// Get the RTE-Configuration from TSConfig.
							$TS=t3lib_befunc::getPagesTSconfig($thePidValue);
							$thisConfig = $TS['RTE.']['default.'];
							unset($TS);
	// Draw the RTE.
							$RTEobj = &t3lib_BEfunc::RTEgetObj();
							$RTEForm = $RTEobj->drawRTE(&$pObj,$table,$field,$row,$PA,$specConf,$thisConfig,$RTEtypeVal,$RTErelPath,$thePidValue);
							
								// Add needed JS functions.
							$content .= $this->TCEForms->JStop();
							$content .= $RTEForm;
							$content .= $this->TCEForms->JSbottom('editform');

Ich habe rausgefunden, wenn der RTE richtig geladen wird, dann kommt folgender Code raus:

<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/editor_template.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/advhr/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/advhr/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/contextmenu/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/directionality/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/directionality/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/emotions/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/emotions/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/spellchecker/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/spellchecker/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/inlinepopups/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/insertdatetime/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/insertdatetime/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/paste/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/paste/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/preview/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/preview/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/print/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/print/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/searchreplace/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/searchreplace/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/table/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/table/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/zoom/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/cleanup/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3link/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3link/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3image/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3image/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/visualchars/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/visualchars/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/xhtmlxtras/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/xhtmlxtras/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/media/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/media/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/lorem/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/lorem/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/style/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/style/langs/en.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/template/editor_plugin.js">
</script>
<script language="javascript" type="text/javascript" src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/template/langs/en.js">
</script>
<input name="data[tt_content][26][_TRANSFORM_bodytext]" value="RTE" type="hidden">
<textarea style="display: none;" id="RTEarea1" class="RTEarea1" name="data[tt_content][26][bodytext]" rows="15" cols="80" tinyrte="true">&lt;h1&gt;Am Anfang steht Ihre Idee&lt;/h1&gt; &lt;p&gt;Wir leben in einer Welt der ständigen Innovation und mit immer neuen Herausforderungen.&lt;br /&gt;Technologien werden ständig weiterentwickelt und verbessert. Arbeitsabläufe werden optimiert und&lt;br /&gt;komplexe Produkte werden vereinfacht.&lt;/p&gt; &lt;p&gt;Wir bieten ein großes Spektrum an Leistungen, genau auf die heutigen Bedürfnisse zugeschnitten.&lt;br /&gt;Wir beraten, planen und übernehmen alle komplexen Prozesse zur Realisierung neuer&lt;br /&gt;Systemlösungen. Ganz im Sinne einer vernetzten Arbeitsteilung und mit Blick auf die faszinierende&lt;br /&gt;Zukunft einer globalen Wirtschaftswelt.&lt;/p&gt;</textarea><span id="mce_editor_0_parent" class="mceEditorContainer">
<table class="mceEditor" style="width: 652px; height: 398px;" border="0" cellpadding="0" cellspacing="0" height="300" width="100%">
<tbody>
<tr>
	<td dir="ltr" class="mceToolbarTop" align="left" height="1" nowrap="nowrap">
		<span id="mce_editor_0_toolbar" class="mceToolbarContainer"><a href="#" accesskey="q" title="Jump to tool buttons - Alt+Q, Jump to editor - Alt-Z, Jump to element path - Alt-X"></a><a id="mce_editor_0_newdocument" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceNewDocument',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceNewDocument',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/newdocument.gif" title="New document"></a><a id="mce_editor_0_undo" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Undo',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Undo',false);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/undo.gif" title="Undo (Ctrl+Z)"></a><a id="mce_editor_0_redo" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Redo',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Redo',false);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/redo.gif" title="Redo (Ctrl+Y)"></a><a id="mce_editor_0_cut" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Cut',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Cut',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/cut.gif" title="Cut"></a><a id="mce_editor_0_copy" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Copy',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Copy',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/copy.gif" title="Copy"></a><a id="mce_editor_0_paste" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Paste',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Paste',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/paste.gif" title="Paste"></a><a id="mce_editor_0_pastetext" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcePasteText',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mcePasteText',true);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/paste/images/pastetext.gif" title="Paste as Plain Text"></a><a id="mce_editor_0_pasteword" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcePasteWord',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mcePasteWord',true);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/paste/images/pasteword.gif" title="Paste from Word"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_print" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcePrint');" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mcePrint');return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/print/images/print.gif" title="Print"></a><a id="mce_editor_0_help" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceHelp',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceHelp',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/help.gif" title="Help"></a><br>
		<a id="mce_editor_0_bold" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Bold',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Bold',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/bold.gif" title="Bold (Ctrl+B)"></a><a id="mce_editor_0_italic" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Italic',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Italic',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/italic.gif" title="Italic (Ctrl+I)"></a><a id="mce_editor_0_underline" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Underline',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Underline',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/underline.gif" title="Underline (Ctrl+U)"></a><a id="mce_editor_0_strikethrough" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Strikethrough',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Strikethrough',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/strikethrough.gif" title="Strikethrough"></a><a id="mce_editor_0_sub" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','subscript',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','subscript',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/sub.gif" title="Subscript"></a><a id="mce_editor_0_sup" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','superscript',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','superscript',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/sup.gif" title="Superscript"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_justifyleft" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','JustifyLeft',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','JustifyLeft',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/justifyleft.gif" title="Align left"></a><a id="mce_editor_0_justifycenter" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','JustifyCenter',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','JustifyCenter',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/justifycenter.gif" title="Align center"></a><a id="mce_editor_0_justifyright" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','JustifyRight',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','JustifyRight',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/justifyright.gif" title="Align right"></a><a id="mce_editor_0_justifyfull" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','JustifyFull',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','JustifyFull',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/justifyfull.gif" title="Align full"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_bullist" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','InsertUnorderedList',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','InsertUnorderedList',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/bullist.gif" title="Unordered list"></a><a id="mce_editor_0_numlist" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','InsertOrderedList',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','InsertOrderedList',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/numlist.gif" title="Ordered list"></a><a id="mce_editor_0_outdent" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Outdent',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Outdent',false);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/outdent.gif" title="Outdent"></a><a id="mce_editor_0_indent" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','Indent',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','Indent',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/indent.gif" title="Indent"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_hr" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','inserthorizontalrule',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','inserthorizontalrule',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/hr.gif" title="Insert horizontal ruler"></a><a id="mce_editor_0_insertdate" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceInsertDate');" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceInsertDate');return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/insertdatetime/images/insertdate.gif" title="Insert date"></a><br>
		<span id="mce_editor_0_forecolor" dir="ltr" class="mceMenuButton"><a href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','forecolor',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','forecolor',true);return false;" onmousedown="return false;" class="mceMenuButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/forecolor.gif" title="Select text color"></a><a href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','forecolorMenu');" onclick="tinyMCE.execInstanceCommand('mce_editor_0','forecolorMenu');return false;" onmousedown="return false;"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/button_menu.gif" title="Select text color" class="mceMenuButton"></a></span><span id="mce_editor_0_backcolor" dir="ltr" class="mceMenuButton"><a href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','HiliteColor',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','HiliteColor',true);return false;" onmousedown="return false;" class="mceMenuButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/backcolor.gif" title="Select background color"></a><a href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','HiliteColorMenu');" onclick="tinyMCE.execInstanceCommand('mce_editor_0','HiliteColorMenu');return false;" onmousedown="return false;"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/button_menu.gif" title="Select background color" class="mceMenuButton"></a></span><a id="mce_editor_0_typo3link" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcetypo3link',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mcetypo3link',true);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3link/images/image.gif" title="Insert/Modify link"></a><a id="mce_editor_0_unlink" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','unlink',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','unlink',false);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/unlink.gif" title="Unlink"></a><a id="mce_editor_0_anchor" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceInsertAnchor',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceInsertAnchor',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/anchor.gif" title="Insert/edit anchor"></a><a id="mce_editor_0_charmap" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceCharMap',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceCharMap',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/charmap.gif" title="Insert custom character"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_typo3image" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcetypo3image',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mcetypo3image',true);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/typo3image/images/image.gif" title="Insert/Modify Image"></a><a id="mce_editor_0_table" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceInsertTable',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceInsertTable',true);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/table/images/table.gif" title="Inserts a new table"></a><a id="mce_editor_0_visualaid" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceToggleVisualAid',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceToggleVisualAid',false);return false;" onmousedown="return false;" class="mceButtonSelected" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/visualaid.gif" title="Toggle guidelines/invisible elements"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_insertlayer" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceInsertLayer',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceInsertLayer',true);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/images/insertlayer.gif" title="Insert new layer"></a><a id="mce_editor_0_absolute" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceMakeAbsolute',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceMakeAbsolute',true);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/images/absolute.gif" title="Toggle absolute positioning"></a><a id="mce_editor_0_moveforward" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceMoveForward',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceMoveForward',true);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/images/moveforward.gif" title="Move forward"></a><a id="mce_editor_0_movebackward" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceMoveBackward',true);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceMoveBackward',true);return false;" onmousedown="return false;" class="mceButtonDisabled" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/layer/images/movebackward.gif" title="Move backward"></a><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2"><a id="mce_editor_0_removeformat" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','removeformat',false);" onclick="tinyMCE.execInstanceCommand('mce_editor_0','removeformat',false);return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/removeformat.gif" title="Remove formatting"></a><a id="mce_editor_0_inserttime" href="javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceInsertTime');" onclick="tinyMCE.execInstanceCommand('mce_editor_0','mceInsertTime');return false;" onmousedown="return false;" class="mceButtonNormal" target="_self"><img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/plugins/insertdatetime/images/inserttime.gif" title="Insert time"></a><br>
		<select id="mce_editor_0_styleSelect" onmousedown="tinyMCE.themes.advanced._setupCSSClasses('mce_editor_0');" name="mce_editor_0_styleSelect" onfocus="tinyMCE.addSelectAccessibility(event,this,window);" onchange="tinyMCE.execInstanceCommand('mce_editor_0','mceSetCSSClass',false,this.options[this.selectedIndex].value);" class="mceSelectList">
			<option value="">-- Styles --</option>
		</select>
		<img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2">
		<select id="mce_editor_0_formatSelect" name="mce_editor_0_formatSelect" onfocus="tinyMCE.addSelectAccessibility(event, this, window);" onchange="tinyMCE.execInstanceCommand('mce_editor_0','FormatBlock',false,this.options[this.selectedIndex].value);" class="mceSelectList">
			<option value="">-- Format --</option>
			<option value="&lt;p&gt;">Paragraph</option>
			<option value="&lt;address&gt;">Address</option>
			<option value="&lt;pre&gt;">Preformatted</option>
			<option value="&lt;h1&gt;">Heading 1</option>
			<option value="&lt;h2&gt;">Heading 2</option>
			<option value="&lt;h3&gt;">Heading 3</option>
			<option value="&lt;h4&gt;">Heading 4</option>
			<option value="&lt;h5&gt;">Heading 5</option>
			<option value="&lt;h6&gt;">Heading 6</option>
		</select>
		<img src="https://arnotec.mine.nu/intern/app/typo3/arnotec/typo3conf/ext/tinyrte/tiny_mce/themes/advanced/images/separator.gif" class="mceSeparatorLine" height="20" width="2">
		<select id="mce_editor_0_fontSizeSelect" name="mce_editor_0_fontSizeSelect" onfocus="tinyMCE.addSelectAccessibility(event, this, window);" onchange="tinyMCE.execInstanceCommand('mce_editor_0','FontSize',false,this.options[this.selectedIndex].value);" class="mceSelectList">
			<option value="0">-- Font size --</option>
			<option value="1">1 (8 pt)</option>
			<option value="2">2 (10 pt)</option>
			<option value="3">3 (12 pt)</option>
			<option value="4">4 (14 pt)</option>
			<option value="5">5 (18 pt)</option>
			<option value="6">6 (24 pt)</option>
			<option value="7">7 (36 pt)</option>
		</select>
		<br>
		<a href="#" accesskey="z" onfocus="tinyMCE.getInstanceById('mce_editor_0').getWin().focus();"></a></span>
	</td>
</tr>
<tr>
	<td align="center">
		<iframe style="width: 908px; height: 273px;" allowtransparency="true" topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" border="0" class="mceEditorIframe" name="mce_editor_0" id="mce_editor_0" frameborder="0" height="185" width="100%">
		</iframe>
	</td>
</tr>
<tr>
	<td class="mceStatusbarBottom" height="1">
		<div id="mce_editor_0_path" class="mceStatusbarPathText" style="display: block;">
			<a href="#" accesskey="x"></a>Path: &nbsp;
		</div>
		<div id="mce_editor_0_resize" class="mceStatusbarResize" style="display: block;" onmousedown="tinyMCE.themes.advanced._setResizing(event,'mce_editor_0',true);">
		</div>
		<br style="clear: both;">
	</td>
</tr>
</tbody>
</table>
<span id="mce_editor_0_resize_box" class="mceResizeBox"></span>
<div class="mceBlockBox" id="mce_editor_0_spellcheckerBlockBox">
</div>
<div class="mceMsgBox" id="mce_editor_0_spellcheckerMsgBox">
</div>
</span>
</td>
<td>
<table border="0" cellpadding="4" cellspacing="0">
<tbody>
<tr>
	<td>
		<a href="wizard_rte.php?&amp;P%5Bparams%5D=&amp;P%5BexampleImg%5D=&amp;P%5Btable%5D=tt_content&amp;P%5Buid%5D=26&amp;P%5Bpid%5D=58&amp;P%5Bfield%5D=bodytext&amp;P%5Bmd5ID%5D=ID207233636e&amp;P%5BreturnUrl%5D=%2Fintern%2Fapp%2Ftypo3%2Farnotec%2Ftypo3%2Falt_doc.php%3F%26returnUrl%3D%252Fintern%252Fapp%252Ftypo3%252Farnotec%252Ftypo3conf%252Fext%252Ftemplavoila%252Fmod1%252Findex.php%253Fid%253D58%26edit%5Btt_content%5D%5B26%5D%3Dedit" onclick="this.blur();return !TBE_EDITOR.isFormChanged();"><img src="sysext/t3skin/icons/gfx/wizard_rte2.gif" alt="Full screen Rich Text Editing" title="Full screen Rich Text Editing" border="0" height="15" width="18"></a>
	</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>

Bei mir steht aber immer nur folgendes:

<textarea id="RTEarea" class="RTEarea" name="" rows="15" cols="80" tinyRTE="true">
</textarea>

Ich denke mal, irgendetwas mache ich falsch beim initialisieren des Editors. Zumindest bekomm ich es einfach nicht hin, dass er in meinen Code die scripts mit übernimmt, bzw. den Editor richtig rendert.

Gruß,
Spyro

P.S.: sry, dass die codeschnipsel so groß sind, aber ich dachte, besser n bisschen mehr, als zu wenig.

fritze3001 ·

mhmm, in der extension ist der RTE aber wieder im BE nur als plugin eingebunden. gibt es keine möglichkeit ein RTE in einem BE Modul (mod) einzubinden?

Spyro ·

hat zwar nicht direkt was mit dem thema zu tun, aber trotzdem die frage hier rein.
wenn ich mir den framequelltext anzeigen lasse und mir den RTE Quelltext anschaue, so fehlen diesem die javascripts und tabellen für die einzelnen funktionen (bsp.: advhr, contextmenu, etc...; siehe oben). markiere ich aber den RTE und lasse mir den auswahlquelltext anzeigen, so sind sie auf einmal wieder da.
woran liegt das?

EDIT: Ist vielleicht grad jemand in der Lage mir zu zeigen, wo genau im T3-Code die Javascripts hinzugefügt werden? Ich hab jetzt etliche Funktionen zurückverfolgt, aber konnte nirgends festellen, wo die javascript-zeilen, geschweige denn die tabellen für die symbole(+funktionen) gerendert werden. Wenns zu viel verlangt ist, dann haut mich 🙂

Spyro

Spyro ·

ich habe gerade eben rausgefunden, woran es bei mir lag.

Und zwar werden die Javascripts für den RTE (bei mir der TinyRTE) falsch verlinkt.
Die werden im Code für den Editor über t3lib_extMgm:extRelPath eingebunden, d.h. relativ zum TYPO3-MainDir und nicht relativ zum Ausführungsort.

Dann kommt da immer soetwas wie

<script language="javascript" type="text/javascript" src="../typo3conf/ext/tinyrte/tiny_mce/tiny_mce.js"></script>

dabei raus.
Wenn man den RTE aber in dem Backendmodul haben will müssen da logischerweise die ganzen Unterordner wie mod1 etc. berücksichtig werden, weswegen da ein paar "../" fehlen.
Entweder macht man das ganze dann mit der schönen Extension names "tinymce", oder man bindet die eine HTML-Zeile einfach selbst ein 🙂

Soweit zu meinem Wissenstand 🙂

Spyro

Edit:
Bei mir sieht das dann beispielsweise so aus:

$content = '<script type="text/javascript" src="../../../'.t3lib_extMgm::extRelPath("tinyrte").'tiny_mce/tiny_mce.js"></script>';

$content .= $this->TCEForms->getSingleField_typeText($table,$field,$row,&$PA);
steffenk ·

Da sollte Dir die var $BACK_PATH helfen, da die immer auf den typo3-Ordner zeigt, also ein Konstrukt wie:

$path=$BACK_PATH.'../'.t3lib_extMgm::extRelPath("tinyrte");
Spyro ·

jup :-) genau das habe ich gerade getahn :-)

Noch für alle anderen, die den TinyRTE benutzten, ein kleiner Tip (Ich wusste nicht, wie man so eine *.diff-Datei erstellt, deswegen der Holzweg)

Ihr geht in die class.tx_tinyrte_base.php

Dort ändert ihr folgendes ab:

In die globals nehmt ihr die $BACK_PATH mit auf.

1)
Change: $css='../'.$globalConf["MCEstyle"];
To: $css=$BACK_PATH.'../'.$globalConf["MCEstyle"];

2)
Change: <script language="javascript" type="text/javascript" src="'.t3lib_extmgm::extRelPath("tinyrte").'tiny_mce/'.$script.'"></script>
To: <script language="javascript" type="text/javascript" src="'.$BACK_PATH.t3lib_extmgm::extRelPath("tinyrte").'tiny_mce/'.$script.'"></script>

und schon werden überall die Pfade automatisch richtig angepasst und ihr müsst euch keine sorgen mehr um die verlinkung machen. Ich hab das auch schon als bugreport abgeschickt, ich hoffe es hilft den leuten :-)

Viel Spaß noch :-)

Spyro

mischa ·

Ich könnte mal bitte eure Hilfe brauchen. Dies hier ist der einzige brauchbare Thread über das Einbinden eines RTE im eigenen BE-Modul (mod1). Soweit habe ich auch alle hingekriegt, aber leider will bei meinem Modul der RTE nicht vollständig laden.

Die Pfade passen alle. (Durch FE-Plugin überprüft)

Ich bekomme immer nur die Textarea, aber der ganze andere Sums ist nicht da.

Hat jemand eine Idee?

mischa ·

Ok, etwas popeln und schon geht's...

1. Nutzt du tinyrte guckst du in Handbuch für htmlarea. ;-)
2. Gaaaaanz oben einfügen:

require_once(t3lib_extMgm::extPath('tinyrte').'class.tx_tinyrte_base.php'); //RTE

3. Dann Variablen setzen (gleich nach class halt):

/* RTE vars */
	var $RTEObj;
	var $docLarge = 0;
	var $RTEcounter = 0;
	var $formName;
	var $additionalJS_initial = '';		// Initial JavaScript to be printed before the form (should be in head, but cannot due to IE6 timing bug)
	var $additionalJS_pre = array();	// Additional JavaScript to be printed before the form (works in Mozilla/Firefox when included in head, but not in IE6)
	var $additionalJS_post = array();	// Additional JavaScript to be printed after the form
	var $additionalJS_submit = array();	// Additional JavaScript to be executed on submit
	var $PA = array(
		'itemFormElName' =>  '',
		'itemFormElValue' => '',
	);
	var $specConf = array(
		'rte_transform' => array(
			'parameters' => array('mode' => 'ts_css')
			)
		);
	var $thisConfig = array();
	var $RTEtypeVal = 'text';
	var $thePidValue;

4. Dann dort, wo RTE reinkommen soll:

	$this->postvars = t3lib_div::_POST('tx_tinyrte_base');
if(!$this->RTEObj)  $this->RTEObj = t3lib_div::makeInstance('tx_tinyrte_base');
if($this->RTEObj->isAvailable()) {
	$this->RTEcounter++;
	$this->table = 'tx_geosearch_objects';
	$this->field = 'tx_stadtkunst_description';
	$this->formName = 'stadtkunst';
	$this->PA['itemFormElName'] = 'sk[description]';
	$this->PA['itemFormElValue'] = $this->postvars['description'];
	$this->thePidValue = 0;
	$RTEItem = $this->RTEObj->drawRTE($this, 'tx_geosearch_objects', 'tx_stadtkunst_description', $row=array(), $this->PA, $this->specConf, $this->thisConfig, $this->RTEtypeVal, '', $this->thePidValue);
	$content .= $this->additionalJS_initial.'
		<script type="text/javascript">'. implode(chr(10), $this->additionalJS_pre).'
		</script>';
	$content .= '
		<script type="text/javascript">'. implode(chr(10), $this->additionalJS_post).'
		</script>';
	$content .= implode(';', $this->additionalJS_submit);
	$content .= $RTEItem;
}
lobby ·

Bei mir sind jetzt aber die Arrays $additionalJS_pre und $additionalJS_post leer.
Deshalb wird wahrscheinlich folgender Fehler ausgegeben:

Fatal error: Call to a member function on a non-object in .../typo3/sysext/rtehtmlarea/pi2/class.tx_rtehtmlarea_pi2.php on line 116