I've searched for tutorials about this, but haven't found much. I'm trying to make a simple html editor to see if I can continue with a larger project in mind. PHP comments are displayed as text with a white background and the same happens with javascript functions.

Here's a picture of the URL "http://kff.dbspot.com" used with my current JEditorPane. The table at the bottom was generated through php.