Template keeps full html dom strucuture, but makes use of a number of php includes to fill in most of the fixed text.
Discovered that when I then edit the file in Contribute, it corrupts the file (internal server error). Not sure why, contacted ESG.
Seems any php file with an include is corrupted when edited in Contribute.