<?php
class foo {
//... class goes here ...
}
?>
<html>
<!-- all of my page stuff and CSS goes here -->
<?php
$myClass = new foo();
$myClass->output();
?>
</html>