string wanted editor
* @param context string page context (post,page,comment,event,...)
* @param tags array array of ids to inject editor
*/
public static function adminPostEditor($editor='',$context='',array $tags=array()) {
if (empty($editor) || $editor!='dcLegacyEditor') {return;}
// context and tags are not used for dcLegacyEditor
return
self::jsToolBar().
dcPage::jsLoad(self::$p_url.'/js/_post_editor.js');
}
public static function adminPopupMedia($editor='') {
if (empty($editor) || $editor!='dcLegacyEditor') {return;}
return dcPage::jsLoad(self::$p_url.'/js/jsToolBar/popup_media.js');
}
public static function adminPopupLink($editor='') {
if (empty($editor) || $editor!='dcLegacyEditor') {return;}
return dcPage::jsLoad(self::$p_url.'/js/jsToolBar/popup_link.js');
}
public static function adminPopupPosts($editor='') {
if (empty($editor) || $editor!='dcLegacyEditor') {return;}
return dcPage::jsLoad(self::$p_url.'/js/jsToolBar/popup_posts.js');
}
protected static function jsToolBar() {
$res =
''.
'';
if (isset($GLOBALS['core']->auth) && $GLOBALS['core']->auth->getOption('enable_wysiwyg')) {
$res .= '';
}
$res .=
''.
'\n";
return $res;
}
}