Writes to cfg files

When editing, it now writes out a new configuration file. Some editing bugs fixed, and some some additions to the html and css.