public function renderPage($templateName, $templateVars = false)
 {
     echo $this->render('header', ChesterWPCoreDataHelpers::getBlogInfoData());
     wp_head();
     echo $this->render('header_close', array('siteTitleHTML' => self::renderSiteTitle()));
     echo $this->render($templateName, $templateVars);
     wp_footer();
     echo $this->render('footer');
 }
 public function showPatternPrimer($foldersToConvert = array(), $patternsHTML = "")
 {
     $processedPatternSets = array(array('pathToTemplates' => dirname(__FILE__) . '/templates/', 'patternFolder' => 'patterns/', 'patternsTemplateLoader' => $this->patternPrimerTemplateLoader));
     foreach ($foldersToConvert as $folderToConvert) {
         $processedPatternSet = array('pathToTemplates' => str_replace('//', '/', dirname(__FILE__) . '/') . '../../../mvc/templates/', 'patternFolder' => $folderToConvert . '/', 'patternsTemplateLoader' => $this->coreTemplateLoader);
         array_push($processedPatternSets, $processedPatternSet);
     }
     $blogInfo = ChesterWPCoreDataHelpers::getBlogInfoData();
     echo $this->coreTemplateLoader->render('header', ChesterWPCoreDataHelpers::getBlogInfoData());
     echo $this->patternPrimerTemplateLoader->render('pattern_primer_header', array('syntaxhighlighter_directory' => $blogInfo['template_url'] . '/lib/Chester/lib/syntaxhighlighter_3.0.83/'));
     echo $this->coreTemplateLoader->render('header_close', FALSE);
     echo $this->patternPrimerTemplateLoader->render('pattern_primer_page', array('patterns' => $this->renderPatterns($processedPatternSets) . $patternsHTML));
     echo $this->coreTemplateLoader->render('footer', FALSE);
 }