Multiple stylesheets with TinyMCE
It looks like the TinyMCE editor (the default editor for Wordpress) doesn’t support specifying multiple stylesheets for edited content. This is particularly common, since you’ll generally want to use your site’s CSS, plus a CSS full of overrides for the editor.
There are some helpful tips on the TinyMCE forums, but I’ll sum up the simplest hack here: simply write a PHP file that includes all the stylesheets you want. My file here (copied from forum user “unfold”):
Filename: editor-styles.css.php
$includeme = $_SERVER['DOCUMENT_ROOT'].”/sitesubdir/site-style.css”; if (file_exists($includeme)) {include($includeme);}
$includeme = $_SERVER['DOCUMENT_ROOT'].”/sitesubdir/editor-overrides.css”; if (file_exists($includeme)) {include($includeme);}
?>
I still feel like TinyMCE should offer the option by default, since it’s so common, but I won’t argue with such a quick solution!
