<?php
	global $prof_default;

	$footermaincontainer = "footer-main-container-data-fullwidth";
	$footeruppercontainerdetails = "footer-upper-container-fullwidth";
	$footerbottomdetails = "footer-bottom-container-fullwidth";
	$footerbottommaindetails = "footer-bottom-main-container-fullwidth";
?>

	
	<div class="footer-container">	
		<?php if(of_get_option('select_top_footer_section',$prof_default) == 'On'){ ?>

		<div class="sentient-header-top-container">
		
			<!-- Email/Phone/Socials Container
			================================================== -->		
			<div class="sentient-header-top-internal-container">
				<div class="sentient-header-top-info-container">
					<span class="sentient-header-phone"><?php _e('Call Us: ', 'sentient'); ?><?php echo esc_attr(of_get_option('theme_site_phone',$prof_default)); ?></span>
					<span class="sentient-header-email"><?php _e('Email: ', 'sentient'); ?><a href="mailto:<?php echo esc_attr(of_get_option('theme_site_email',$prof_default)); ?>"><?php echo esc_attr(of_get_option('theme_site_email',$prof_default)); ?></a></span>			
				</div>
				<div class="sentient-header-top-social-container">
					<?php if(of_get_option('flicker_user_account',$prof_default) != ''){ ?>
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-flickr"><a target="_blank" href="<?php echo esc_url(of_get_option('flicker_user_account',$prof_default)); ?>"><i class="icon-flickr"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Flickr', 'sentient'); ?></span>
						</div>
					</div>
					<?php } ?>
					<?php if(of_get_option('vimeo_user_account',$prof_default) != ''){ ?>				
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-vimeo"><a target="_blank" href="<?php echo esc_url(of_get_option('vimeo_user_account',$prof_default)); ?>"><i class="icon-vimeo"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Vimeo', 'sentient'); ?></span>
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('twitter_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-twitter"><a target="_blank" href="<?php echo esc_url(of_get_option('twitter_user_account',$prof_default)); ?>"><i class="icon-twitter"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Twitter', 'sentient'); ?></span>
						</div>					
					</div>
					<?php } ?>	
					<?php if(of_get_option('facebook_user_account',$prof_default) != ''){ ?>						
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-facebook"><a target="_blank" href="<?php echo esc_url(of_get_option('facebook_user_account',$prof_default)); ?>"><i class="icon-facebook"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Facebook', 'sentient'); ?></span>
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('dribbble_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-dribbble"><a target="_blank" href="<?php echo esc_url(of_get_option('dribbble_user_account',$prof_default)); ?>"><i class="icon-dribbble"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Dribbble', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('linkedin_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-linkedin"><a target="_blank" href="<?php echo esc_url(of_get_option('linkedin_user_account',$prof_default)); ?>"><i class="icon-linkedin"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('LinkedIn', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>				
					<?php if(of_get_option('google_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-google"><a target="_blank" href="<?php echo esc_url(of_get_option('google_user_account',$prof_default)); ?>"><i class="icon-gplus"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Google+', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>	
					<?php if(of_get_option('rss_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-rss"><a target="_blank" href="<?php echo esc_url(of_get_option('rss_user_account',$prof_default)); ?>"><i class="icon-rss"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('RSS', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('pinterest_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-pinterest"><a target="_blank" href="<?php echo esc_url(of_get_option('pinterest_user_account',$prof_default)); ?>"><i class="icon-pinterest"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Pinterest', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('github_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-github"><a target="_blank" href="<?php echo esc_url(of_get_option('github_user_account',$prof_default)); ?>"><i class="icon-github"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Github', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('tumblr_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-tumblr"><a target="_blank" href="<?php echo esc_url(of_get_option('tumblr_user_account',$prof_default)); ?>"><i class="icon-tumblr"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Tumblr', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('instagram_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-instagram"><a target="_blank" href="<?php echo esc_url(of_get_option('instagram_user_account',$prof_default)); ?>"><i class="icon-instagram"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Instagram', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>
					<?php if(of_get_option('skype_user_account',$prof_default) != ''){ ?>					
					<div class="sentient-header-top-social-divider">
						<span class="sentient-header-top-info-skype"><a target="_blank" href="<?php echo esc_url(of_get_option('skype_user_account',$prof_default)); ?>"><i class="icon-skype"></i></a></span>
						<div class="sentient-header-top-popup-container animated">
							<span class="sentient-tooltip-top"><?php _e('Skype', 'sentient'); ?></span>		
						</div>					
					</div>
					<?php } ?>			
				</div>			
			</div>
		</div>
		<?php } ?>	
	
		<?php if(of_get_option('select_footer_columns',$prof_default) == 'On') { ?>
		<div class="footer-main-container-data footer-main-container-data-color <?php echo esc_attr($footermaincontainer); ?>">
			<?php
				global $post;
				$args = array( 'numberposts' => 4);
				$myposts = get_posts( $args );
			?>
			<div class="footer-upper-container <?php echo esc_attr($footeruppercontainerdetails); ?>">				
				<div>
					<div class="footer-widget-container">
						<?php if (!function_exists('dynamic_sidebar') || !dynamic_sidebar('Footer Col 1')) { ?>   
							<?php dynamic_sidebar('Footer Col 1'); ?>
						<?php } ?>
					</div>
					<div class="footer-widget-container">
						<?php if (!function_exists('dynamic_sidebar') || !dynamic_sidebar('Footer Col 2')) { ?>   						
							<?php dynamic_sidebar('Footer Col 2'); ?>				
						<?php } ?>
					</div>
					<div class="footer-widget-container">
						<?php if (!function_exists('dynamic_sidebar') || !dynamic_sidebar('Footer Col 3')) { ?>   						
							<?php dynamic_sidebar('Footer Col 3'); ?>				
						<?php } ?>
					</div>					
					<div class="footer-widget-container footer-widget-container-last">					
						<?php if (!function_exists('dynamic_sidebar') || !dynamic_sidebar('Footer Col 4')) { ?>   				
							<?php dynamic_sidebar('Footer Col 4'); ?>		
						<?php } ?>
					</div>
				</div>
			</div>
		</div>
		<?php } ?>
		<?php if(of_get_option('select_copyrights_columns',$prof_default) == 'On') { ?>
		<div class="footer-bottom-container footer-bottom-details">
			<div class="footer-bottom-main-container <?php echo esc_attr($footerbottommaindetails); ?>">
				<?php if(of_get_option('copyrights_above_text',$prof_default) != ''){ ?>
				<div class="above-copyright-footer">
				<?php  echo do_shortcode(of_get_option('copyrights_above_text',$prof_default)); ?>
				</div>
				<?php } ?>
				<div class="footer-bottom-main-container-left">
					<?php 
						$sentient_year = get_the_date( 'Y' , '' , '') ;
						$sentient_get_copyright = of_get_option('footer_text',$prof_default);
						$sentient_final_copyright = str_replace('this_year', $sentient_year, $sentient_get_copyright);
					?>
					<?php echo $sentient_final_copyright; ?>
				</div>
				<div class="footer-bottom-main-container-right">
					<div class="bottom-cont-footer">
						<div class="footer-navigation">
						<?php if(of_get_option('select_copyrights_menu',$prof_default) == 'On') { ?>
							<?php wp_nav_menu( array( 'theme_location' => 'extra-menu' ) ); ?>
						<?php } else { ?>
							<?php  echo of_get_option('copyrights_menu_text',$prof_default); ?>
						<?php } ?>
						</div>								
					</div>
					<?php if(of_get_option('select_backtotop',$prof_default) == 'On') { ?>
					<div class="div-top float-right">
						<i class="icon-up-open"></i>
					</div>
					<?php } ?>
				</div>					
			</div>
		</div>
		<?php } ?>				
	</div>	
</div>
</div>

<?php wp_footer(); ?>
</body>
</html>