<?php
/**
 * @package   T3 Blank
 * @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
 * @license   GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;
defined('_JEXEC') or die;
$bgFooter  = '';

if($this->params->get('bg-footer')) {
	$bgFooter  = 'style="background-image: url('.$this->params->get('bg-footer').');"';
}

$logoFooter = $this->params->get('logo-footer');
?>

<!-- BACK TOP TOP BUTTON -->
<div id="back-to-top" data-spy="affix" data-offset-top="200" class="back-to-top hidden-xs hidden-sm affix-top">
  <button class="btn btn-linear" title="Back to Top"><span class="icon ion-ios-arrow-round-up"></span><span class="element-invisible">empty</span></button>
</div>

<script type="text/javascript">
(function($) {
  // Back to top
  $('#back-to-top').on('click', function(){
    $("html, body").animate({scrollTop: 0}, 500);
    return false;
  });
})(jQuery);
</script>

<!-- FOOTER -->
<footer id="t3-footer" class="wrap t3-footer" <?php echo $bgFooter ;?>>

	<?php if ($this->checkSpotlight('footnav', 'footer-1, footer-2, footer-3, footer-4, footer-5, footer-6')) : ?>
		<!-- FOOT NAVIGATION -->
		<div class="container">
			<?php $this->spotlight('footnav', 'footer-1, footer-2, footer-3, footer-4, footer-5, footer-6') ?>
		</div>
		<!-- //FOOT NAVIGATION -->
	<?php endif ?>

	<section class="t3-copyright">
		<div class="container">
			<div class="row">
				<?php if($logoFooter) : ?>
				<div class="logo-footer col-sm-12 col-md-4">
					<a href="index.php" title="Home">
						<img src="<?php echo $logoFooter ;?>" alt="logo" />
					</a>
				</div>
				<?php endif ;?>

				<div class="<?php echo $logoFooter ? 'col-md-8' : 'col-md-12' ?> copyright <?php $this->_c('footer') ?>">
					<div class="pull-left">
						<?php if ($this->getParam('t3-rmvlogo', 1)): ?>
					<div class="poweredby text-hide">
						<a class="t3-logo t3-logo-small t3-logo-dark" href="http://t3-framework.org" title="<?php echo JText::_('T3_POWER_BY_TEXT') ?>"
						   target="_blank" <?php echo method_exists('T3', 'isHome') && T3::isHome() ? '' : 'rel="nofollow"' ?>><?php echo JText::_('T3_POWER_BY_HTML') ?></a>
					</div>
					<?php endif; ?>

						<jdoc:include type="modules" name="<?php $this->_p('footer') ?>" />
					</div>

					<?php if ($this->countModules('subscribe-footer')) : ?>
				  <div class="subscribe-footer pull-right <?php $this->_c('subscribe-footer') ?>">
				    <jdoc:include type="modules" name="<?php $this->_p('subscribe-footer') ?>" style="raw" />
				  </div>
				  <?php endif ?>
				</div>

				
			</div>
		</div>
	</section>

</footer>
<!-- //FOOTER -->