title = __("Styled editor","dagsopt"); $this->pluginname = $ns->pluginname; $this->file = $ns->file; $this->ns = $ns; } function start(){ add_action('wp_enqueue_scripts', array(&$this,'tuts_mcekit_editor_enqueue')); add_filter('mce_css', array(&$this,'tuts_mcekit_editor_style')); } function tuts_mcekit_editor_enqueue() { $StyleUrl = plugin_dir_url(__FILE__).'editor-styles.css'; wp_enqueue_style( 'myCustomStyles', $StyleUrl ); } function tuts_mcekit_editor_style($url) { if ( !empty($url) ) $url .= ','; // Retrieves the plugin directory URL and adds editor stylesheet // Change the path here if using different directories //$url .= trailingslashit( plugin_dir_url(__FILE__) ) . '/editor-styles.css'; $url .= trailingslashit( get_stylesheet_directory_uri() ) . 'css/bootstrap.css'; $url .= ",".trailingslashit( get_stylesheet_directory_uri() ) . 'style.css'; $url .= ",".trailingslashit( get_stylesheet_directory_uri() ) . 'css/custom.css'; return $url; } function help(){ ?> dagsopt['plug_styled_editor'] = $plug_styled_editor; }