<?php
/** 
* @package WordPress 
* @subpackage restaurant 
*/ 
//========= put you custom code here ============ 
add_action('wp_head', 'addCssStyle');

function addCssStyle(){
	echo "<style type='text/css'>\n";
		echo bm_write_current_bg('body.custom');
	echo "</style> \n";
}

function hook_header(){
?>
	<div id="custom_header" class ="custom_header level2 level3 level4" >
		<div id="header_logo">
			<div class="one"><?php if ( function_exists('custom_header_logo')) custom_header_logo(); ?></div>		
		</div>
		<div id="header_stuff">
			<div class="one"><?php if ( function_exists('custom_header_stuff')) custom_header_stuff(); ?></div>
		</div>
	</div>
	<div class="clear"></div>
<?php
}
add_action('thesis_hook_header', 'hook_header');

function custom_menu(){
?>	
	<div id="custom_menu" class ="custom_menu level2 level3 level4">
		<?php thesis_nav_menu();?>
		<div class="clear"></div>
	</div>
	<div class="clear"></div>
<?php
}
add_action('thesis_hook_after_header', 'custom_menu');

function custom_template(){
	if (is_home() || is_front_page())  {	// this is the home page template 
?>
	<div id="home_page"  class="home_page level2 level3 level4" >
		<div id="top_content" class="top_content" >
			<div class="clear"></div>
			<div class="one"><?php if ( function_exists('home_page_top_content_one')) home_page_top_content_one(); ?></div>					
			<div class="two"><?php if ( function_exists('home_page_top_content_two')) home_page_top_content_two(); ?></div>
			<div class="three"><?php if ( function_exists('home_page_top_content_three')) home_page_top_content_three(); ?></div>
			<div class="four"><?php if ( function_exists('home_page_top_content_four')) home_page_top_content_four(); ?></div>
			<div class="clear"></div>	
		</div>
		<div id="bottom_content" class="bottom_content" >			
			<div class="one"><?php if ( function_exists('home_page_bottom_content_one')) home_page_bottom_content_one(); ?></div>
			<div class="two"><?php if ( function_exists('home_page_bottom_content_two')) home_page_right_content_two(); ?></div>
		</div>
		<div class="clear"></div>
	</div>
<?php 
	}else{
?>
	<div id="other_page"  class="other_page level2 level3 level4" >
		<div id="top_content" class="top_content" >
			<div class="one"><?php if ( function_exists('other_page_top_content_one')) other_page_top_content_one(); ?></div>					
			<div class="two"><?php if ( function_exists('other_page_top_content_two')) other_page_top_content_two(); ?></div>
			<div class="three"><?php if ( function_exists('other_page_top_content_three')) other_page_top_content_three(); ?></div>
			<div class="four"><?php if ( function_exists('other_page_top_content_four')) other_page_top_content_four(); ?></div>
			<div class="clear"></div>	
		</div>
		<div id="bottom_content" class="bottom_content" >
			<div class="one"><?php if ( function_exists('other_page_bottom_content_one')) other_page_bottom_content_one(); ?></div>					
			<div class="two"><?php if ( function_exists('other_page_bottom_content_two')) other_page_bottom_content_two(); ?></div>
			<div class="three"><?php if ( function_exists('other_page_bottom_content_three')) other_page_bottom_content_three(); ?></div>
			<div class="four"><?php if ( function_exists('other_page_bottom_content_four')) other_page_bottom_content_four(); ?></div>
			<div class="clear"></div>
		</div>
		<div class="clear"></div>
	</div>
<?php
	}
}
add_action('thesis_hook_custom_template', 'custom_template');

/* Custom 404 Hooks */
function custom_thesis_404_title() {	
	
?>
You have reached a page that does not exist.
<?php
}

add_action('thesis_hook_404_title', 'custom_thesis_404_title');

function custom_thesis_404_content() {
global $site_url;
?>
<p>Please use the navigation to find what you are looking for.
<?php 
	echo '<script type="text/javascript" >window.location.href = "'.$site_url.'";</script>';
?>
</p>

<?php
}

add_action('thesis_hook_404_content', 'custom_thesis_404_content');

function add_custom_footer () { 
?>
	<div id="custom_footer" class="custom_footer level2 level3 level4" >
		<div id="footer_top" class="footer_top">
			<div class="one"><?php if ( function_exists('custom_footer_one')) custom_footer_one(); ?></div>				
			<div class="two"><?php if ( function_exists('custom_footer_two')) custom_footer_two(); ?></div>
			<div class="three"><?php if ( function_exists('custom_footer_three')) custom_footer_three(); ?></div>
			<div class="four"><?php if ( function_exists('custom_footer_four')) custom_footer_four(); ?></div>
			<div class="clear"></div>
		</div>
		<div id="footer_bottom" class="footer_bottom">
			Content &#169; <?php echo date("Y"); ?> All Rights Reserved Design and Development by <a href="http://www.dennisonwolfe.com" title="Dennison+Wolfe Internet Group" target="_blank">Dennison+Wolfe Internet Group</a>
		</div>
		<div class="clear"></div>
	</div>
<?php }
	add_action('thesis_hook_footer', 'add_custom_footer');
?>