As liquorvicar asked, we need some clarification on whether you want this script to output the text "<?php include('header.htm') ?>" or if you actually want to load the header.htm file and output its data.
Also, it might be easier for you to use the HEREDOC syntax:
$output = <<<END_OF_STRING
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN
http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title>TA Generic Procedures - {$title}</title>
etc.
END_OF_STRING;