[Fusionforge-commits] r16498 - trunk/src/plugins/headermenu/view/admin

Franck VILLAUME nerville at fusionforge.org
Wed Oct 10 11:06:00 CEST 2012


Author: nerville
Date: 2012-10-10 11:05:58 +0200 (Wed, 10 Oct 2012)
New Revision: 16498

Modified:
   trunk/src/plugins/headermenu/view/admin/updateLinkValue.php
Log:
add support for fckeditor in update page

Modified: trunk/src/plugins/headermenu/view/admin/updateLinkValue.php
===================================================================
--- trunk/src/plugins/headermenu/view/admin/updateLinkValue.php	2012-10-10 08:49:47 UTC (rev 16497)
+++ trunk/src/plugins/headermenu/view/admin/updateLinkValue.php	2012-10-10 09:05:58 UTC (rev 16498)
@@ -67,8 +67,22 @@
 	$select_name = 'typemenu';
 	echo html_build_radio_buttons_from_arrays($vals, $texts, $select_name, $linkValues['linktype'], false);
 	echo '</td>';
-	echo '</tr><tr id="htmlcode" style="display:none" >';
-	echo '<td>'._('Your HTML Code.').'</td><td><textarea name="htmlcode" rows="15" cols="70">'.$linkValues['htmlcode'].'</textarea></td>';
+	echo '</tr><tr id="htmlcode" style="display:none">';
+	echo '<td>'._('Your HTML Code.').'</td><td>';
+	$GLOBALS['editor_was_set_up'] = false;
+	$body = $linkValues['htmlcode'];
+	$params['name'] = 'htmlcode';
+	$params['body'] = $body;
+	$params['width'] = "800";
+	$params['height'] = "500";
+	$params['user_id'] = user_getid();
+	plugin_hook("text_editor", $params);
+	if (!$GLOBALS['editor_was_set_up']) {
+		echo '<textarea name="htmlcode" rows="5" cols="80">'.$body.'</textarea>';
+	}
+	unset($GLOBALS['editor_was_set_up']);
+	echo '</td></tr><tr id="urlcode" >';
+	echo '<td>'._('URL').'</td><td><input name="link" type="text" maxsize="255" /></td>';
 	echo '</tr><tr id="urlcode"  style="display:none" >';
 	echo '<td>'._('URL').'</td><td><input name="link" type="text" maxsize="255" value="'.$linkValues['url'].'" /></td>';
 	echo '</tr><tr>';




More information about the Fusionforge-commits mailing list