NicEdit generates bad, non standards complient code that is different in every browser and breaks the editor if editing on a different browser then the one used to create the content.
Style application and HTML clean up is the most complex challenge in writing a WYSIWYG and one that I never quite got too yet with nicEdit. There are 2 components for a fully XHTML compliant system:
For now the nicXHTML plugin is very experimental and does not solve this issue completely. To try it out configure you download with nicXHTML and then add {xhtml : true} to your options. There are many known issues with the implementation.
Another option that I have recommended which maybe work for some people is to use server side cleanup based strategies such as the PHP's tidy functions to clean the HTML produced by nicEdit. However, this solution wont be available for everyone, adds complexity, and is not ideal.
There is alot of work to do on this, doing it correctly is a little more complex then just lifting another implementation like tinyMCE and throwing it into nicEdit. NicEdit is a side project I do have a fulltime job so don't have the few weeks free time this would take. But ill keep working away when I can and welcome any patches to fix nicXHTML as well as anyone implementing a new plugin that works better (ill include any 3ed party plugins in the downloader).
$_POST['body'],
array(
'show-body-only' => true,
'doctype' => '-//W3C//DTD XHTML 1.0 Transitional//EN',
'output-xhtml' => true
)
);