<?php
global $options;
foreach ($options as $value) {
    if (get_settings( $value['id'] ) === FALSE) { $$value['id'] = $value['std']; } else { $$value['id'] = get_settings( $value['id'] ); }
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />

<title><?php if (is_home () ) {
    bloginfo('name');
} elseif ( is_category() ) {
    single_cat_title(); echo ' - ' ; bloginfo('name');
} elseif (is_single() ) {
    single_post_title();
} elseif (is_page() ) {
    bloginfo('name'); echo ': '; single_post_title();
} else {
    wp_title('',true);
} ?>
</title>

<meta name="description" content="<?php bloginfo('description') ?>" />
<?php if ( is_search() || is_author() ) : ?><meta name="robots" content="noindex, nofollow" /><?php endif ?>

<link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" />
<link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Feed" href="<?php if (strlen($wpzoom_misc_feedburner) < 10) { bloginfo('rss2_url');} else {echo"$wpzoom_misc_feedburner";} ?>" />
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_directory'); ?>/css/ie7.css" />
<![endif]-->
<!--[if IE 6]>
 <script src="<?php bloginfo('template_directory'); ?>/js/menu.js"></script>
 <link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_directory'); ?>/css/ie6.css" />

<![endif]-->
  
<?php if (is_home() && $paged < 2) { ?>
<script src="<?php bloginfo('template_url'); ?>/js/tabs.js" type="text/javascript"></script>
<?php }?> 
 
<style type="text/css">
img,h2 { behavior: url(<?php bloginfo('stylesheet_directory'); ?>/iepngfix.htc); }
</style>

<?php remove_action('wp_print_styles', 'pagenavi_stylesheets'); ?>
<?php if ( is_singular() ) wp_enqueue_script( 'comment-reply' );  ?>
<?php wp_head(); ?>
</head>

<body>
 
	<div id="header">
	
		<div id="logo">
			<a href="<?php echo get_option('home'); ?>"><?php if ($wpzoom_misc_logo_path) { ?><img src="<?php echo "$wpzoom_misc_logo_path";?>" alt="<?php bloginfo('name'); ?>" /><?php } else { ?><img src="<?php bloginfo('stylesheet_directory'); ?>/images/logo.png" alt="<?php bloginfo('name'); ?>" /><?php } ?></a>
 		</div>
      
		<?php if (strlen($wpzoom_ad_head_imgpath) > 1 && $wpzoom_ad_head_select == 'Yes') { echo '<div id="ad468">'.stripslashes($wpzoom_ad_head_imgpath)."</div>"; }?>
		
	</div>

	<div id="menu">
		<div id="menu-wrap">
			<ul id="nav" class="nav">

				<li <?php if ( is_home() ) : ?> class="current_page_item"<?php endif; ?>><a href="<?php echo get_option('home'); ?>/">Home</a></li>
				<?php 
				
				$z = 0; $que = "";
				$z = count($wpzoom_exclude_pages_menu);
				if ($z > 0)
				{
				  $x = 0;
				  $que = "";
				  while ($x < $z)
				  {
					$que .= $wpzoom_exclude_pages_menu[$x];
					$x++;
					if ($x < $z) {$que .= ",";}
				  }
				}
				else
				{
				  $que = "";
				}
				
				wp_list_pages("exclude=$que&title_li="); ?>
				
					<?php if ($wpzoom_menu_blog_show == 'Yes')  { ?><li><a href="#"><?php echo"$wpzoom_blog_menu"; ?></a>
						<ul class="children"><?php 
							$z = count($wpzoom_exclude_cats_menu);
						  if ($z > 0)
						  {
							$x = 0;
							$que = "";
							while ($x < $z)
							{
							  $que .= $wpzoom_exclude_cats_menu[$x];
							  $x++;
							  if ($x < $z) {$que .= ",";}
							}
						  }
						  else
						  {
							$que = "";
						  }
						  
						  $menu = preg_replace('@\<li([^>]*)>\<a([^>]*)>(.*?)\<\/a>@i', '<li$1><a$2>$3</a>', wp_list_categories("echo=0&exclude=$que&title_li=")); 
						  echo"$menu"; 
						  ?>
						</ul>
					</li><?php } // if Categories tab should be shown ?>
				</ul> 
			
			<div id="rss">
			
				<ul>
				
					<li class="rssimg"><a href="<?php if (strlen($wpzoom_misc_feedburner) < 10) { bloginfo('rss2_url');} else {echo"$wpzoom_misc_feedburner";} ?>">RSS Feed</a></li>
 					<?php if (strlen($wpzoom_misc_feedburnerID) > 0) {?><li class="emailimg"><a href="http://feedburner.google.com/fb/a/mailverify?uri=<?php echo"$wpzoom_misc_feedburnerID"; ?>&amp;loc=en_US">Subscribe via E-mail</a></li><?php } ?>
				
				</ul>
				
			</div>
		
		
			<div id="search"> 
				<?php include (TEMPLATEPATH . '/searchform.php'); ?>  
			</div>
			
		</div> <!-- end menu wrap -->
    
    </div> <!-- end menu -->
    
    
	<div id="content-wrap">
		<div id="content">