Topic: Help with footer

I have a header and footer for my site. My forum also has the PunBB header and footer. I want to join my site's header to the header of my Forum - it works perfectly fine. However, when I do the same to the Footers, it will not include the footer for my site, and it will only include the footer of my forum. The "<DOCTYPE=>/<head>/<body>" tags have been removed from the header.php. My site's main header/footer are to be joined together with a row from a table, such as this:

tmpl_header.php:
<?php
//blah,blah - (HTML Layouts and codes)
<table>
  <tr>
    <td>
      <!-- Start content -->
?>
--------------------------------------------
tmpl_footer.php:
<?php
<!-- End content -->
    </td>
  </tr>
</table>

//blah,blah - (Ending HTML Layouts and codes)
?>

The system looks approx like this:

header.php:
<?php
/*REQUIRE IS AT THE ABSOLUTE TOP OF PAGE*/
require "tmpl_header.php";

blahablablablahblah..... (Forum Header Script)
?>
---------------------------------
my scripts/pages......
---------------------------------
footer.php:
<?php
blahablablablahblah..... (Forum Footer Script)

/*REQUIRE IS AT THE ABSOLUTE END OF PAGE*/
require "tmpl_footer.php";
?>

Pretty much, the footer looks exactly like this:

// END SUBST - <pun_include "*">


// Close the db connection (and free up any result data)
$db->close();

// Spit out the page
exit($tpl_main);

require "tmpl_footer.php"; /*THIS IS THE MAJOR FOOTER*/

?>

So, where should I require/include my "tmpl_footer.php".

I have been trying to solve this problem for days, but still no positive results.
Any help would be appreciated.