on the pages that are based on the theme, the code that defines the theme will look similar to this:
if("" == ""){
$WA_untitled_1339594149731_Content_Empty = "";
$WA_untitled_1339594149731_Content = new WA_Include(__FILE__);
$WA_untitled_1339594149731_Template = new WA_Include("Templates{$WA_untitled_1339594149731_Content_Empty}/untitled.dwt.php");
require($WA_untitled_1339594149731_Template->BaseName);
$WA_untitled_1339594149731_Template->Initialize(true);
}
the code from the head of the template will be added where that code is in the page that uses the theme. Place the theme code before the other code in your page so the theme code will be executed before the page code.