echo $analytics; } } } add_action('wp_footer', 'thb_google_analytics'); /** * Theme customizations * ----------------------------------------------------------------------------- */ $thb_page = $thb_theme->getAdmin()->getMainPage(); $thb_tab = $thb_page->getTab('layout'); $thb_container = $thb_tab->getContainer('layout_options_footer'); $sep = ' '; $thb_field = new THB_SelectField('footer_layout'); $thb_field->setLabel(__('Layout', 'thb_text_domain')); $thb_field->addOptionsGroup(__('None', 'thb_text_domain'), array('0' => "-")); $thb_field->addOptionsGroup(__('One column', 'thb_text_domain'), array('full-width' => __('Full width', 'thb_text_domain'))); $thb_field->addOptionsGroup(__('Two columns', 'thb_text_domain'), array('one-half,one-half' => "1/2 {$sep} 1/2", 'one-third,two-thirds' => "1/3 {$sep} 2/3", 'two-thirds,one-third' => "2/3 {$sep} 1/3", 'one-fourth,three-fourths' => "1/4 {$sep} 3/4", 'three-fourths,one-fourth' => "3/4 {$sep} 1/4")); $thb_field->addOptionsGroup(__('Three columns', 'thb_text_domain'), array('one-third,one-third,one-third' => "1/3 {$sep} 1/3 {$sep} 1/3", 'one-fourth,one-half,one-fourth' => "1/4 {$sep} 1/2 {$sep} 1/4", 'one-half,one-fourth,one-fourth' => "1/2 {$sep} 1/4 {$sep} 1/4", 'one-fourth,one-fourth,one-half' => "1/4 {$sep} 1/4 {$sep} 1/2")); $thb_field->addOptionsGroup(__('Four columns', 'thb_text_domain'), array('one-fourth,one-fourth,one-fourth,one-fourth' => "1/4 {$sep} 1/4 {$sep} 1/4 {$sep} 1/4")); $thb_field->setHelp(__('Select the columns layout for the footer area. Selecting none will disable the footer area entirely.', 'thb_text_domain')); $thb_container->addField($thb_field); // Add page layout options // ----------------------------------------------------------------------------- $page_templates = array('default', 'template-archives.php', 'template-contact.php', 'template-blog-stream.php', 'template-blog-classic.php', 'template-photogallery.php', 'template-portfolio.php'); $single_post = array('single.php'); $page_layout_templates = array_merge($page_templates, $single_post); $thb_pages = $thb_theme->getPostType('page'); // Pages options --------------------------------------------------------------- if (!function_exists('thb_theme_layout_options')) { function thb_theme_layout_options()