Example #1
0
function bayfront_do_footer_bottom()
{
    // Open layout wrap
    wpsight_layout_wrap('footer-bottom-wrap');
    ?>

	<div id="footer-bottom" class="clearfix">
			
		<div id="bottom-menu">
		
			<?php 
    echo wpsight_menu('bottom');
    ?>
		
		</div><!-- #bottom-menu -->
		<?php 
    $credit = wpsight_get_option('credit');
    // Set default value if option has not been set
    if (wpsight_get_option('credit') === false) {
        $credit = wpsight_get_option('credit', true);
    }
    ?>
		<div id="footer-contact-info">
			<?php 
    // Open layout wrap
    wpsight_layout_wrap('credit-wrap');
    ?>
			<div id="credit" class="clearfix">			    
				<?php 
    echo do_shortcode($credit);
    ?>
			</div><!-- #credit --><?php 
    // Close layout wrap
    wpsight_layout_wrap('credit-wrap', 'close');
    ?>
		</div>
		
		<?php 
    // Loop through social icons
    $nr = apply_filters('wpsight_social_icons_nr', 5);
    $social_icons = array();
    for ($i = 1; $i <= $nr; $i++) {
        $social_icons[] = wpsight_get_social_icon(wpsight_get_option('icon_' . $i));
    }
    // Remove empty elements
    $social_icons = array_filter($social_icons);
    $output = '<div class="social-icons">';
    if (!empty($social_icons)) {
        $i = 1;
        foreach ($social_icons as $k => $v) {
            $social_link = wpsight_get_option('icon_' . $i . '_link');
            $output .= '<a href="' . $social_link . '" target="_blank" title="' . $v['title'] . '" class="social-icon social-icon-' . $v['id'] . '"><img src="' . $v['icon'] . '" alt="" /></a>' . "\n";
            $i++;
        }
    } else {
        $social_icon = wpsight_get_social_icon('rss');
        $output .= '<a href="' . get_bloginfo_rss('rss2_url') . '" target="_blank" title="' . $social_icon['title'] . '" class="social-icon social-icon-' . $social_icon['id'] . '"><img src="' . $social_icon['icon'] . '" alt="" /></a>' . "\n";
    }
    $output .= '</div><!-- .social-icons -->';
    echo apply_filters('wpsight_social_icons_top', $output);
    echo '<div class="subscribe-form">';
    if (function_exists('newsletter_form')) {
        newsletter_form(1);
    }
    echo '</div>';
    ?>
		
		</div><!-- #footer-bottom --><?php 
    // Close layout wrap
    wpsight_layout_wrap('footer-bottom-wrap', 'close');
}
Example #2
0
function wpsight_do_submenu()
{
    if (!has_nav_menu('menu-sub')) {
        return;
    }
    // Open layout wrap
    wpsight_layout_wrap('submenu-wrap');
    ?>

	<div id="submenu">	
		<?php 
    echo wpsight_menu('sub', false);
    ?>
		
	</div><!-- .submenu --><?php 
    // Close layout wrap
    wpsight_layout_wrap('submenu-wrap', 'close');
}