{extends 'main-layout.php'}

{var $sectionsOrder = isset($post->options('sections-order')->overrideGlobal) ? $post->options('sections-order')->order : null}

{block content}
<!-- TOOLBAR -->
<div class="toolbar">
	<div id="breadcrumb">{_}You are here: {/_}{breadcrumbs}</div>
	{include general-search-form.php}
</div>

<!-- SUBPAGE -->
<div id="container" class="subpage subpage-line clear clearfix {isActiveSidebar subpages-sidebar}{else}onecolumn{/isActiveSidebar}">
	<!-- MAINBAR -->
	<div id="content" class="mainbar entry-content clearfix">
		<div class="{isActiveSidebar subpages-sidebar}left leftContent{else}content{/isActiveSidebar}">
			<h1>{$post->title}</h1>
			{if $post->thumbnailSrc != false }
			<div class="entry-thumbnail">
				{isActiveSidebar subpages-sidebar}
					<img src="{$timthumbUrl}?src={$post->thumbnailSrc}&w=644" alt="" />
					{else}<img class=" nosidebar" src="{$timthumbUrl}?src={$post->thumbnailSrc}&w=984" alt="" />
				{/isActiveSidebar}
				
			</div>
			{/if}
			<div class="border-holder">
				{!$post->content}
			</div>
		</div>
		{include snippet-comments.php}
	</div><!-- end of mainbar -->
	{isActiveSidebar subpages-sidebar}
		<!-- SIDEBAR -->
	<div class="sidebar right clearfix">
		{dynamicSidebar subpages-sidebar}
	</div>
	{/isActiveSidebar}
</div><!-- end of container -->
{/block}

{? isset($post->options('slider')->overrideGlobal) ? $localslider = 'slider' : $localslider = 'xb'}
{define $localslider}
  <div class="slider-holder">
  {include snippet-custom-home-slider.php,
  	options => $post->options('slider'),
  	slides => $site->create('slider-creator', $post->options('slider')->sliderType),
  	name => $name,
  	desc => $desc
  }
  {include snippet-custom-home-slider.php,
  	options => $post->options('slider'),
  	slides => $site->create('slider-creator', $post->options('slider')->sliderType2),
  	name2 => $name2,
  	desc2 => $desc2
  }
  {include snippet-custom-home-slider.php,
  	options => $post->options('slider'),
  	slides => $site->create('slider-creator', $post->options('slider')->sliderType3),
  	name3 => $name3,
  	desc3 => $desc3
  }
  {include snippet-custom-home-slider.php,
  	options => $post->options('slider'),
  	slides => $site->create('slider-creator', $post->options('slider')->sliderType4),
  	name4 => $name4,
  	desc4 => $desc4
  }
  </div>
{/define}

{? isset($post->options('testimonials')->overrideGlobal) ? $sectionB = 'sectionB' : $sectionB = 'xb'}
{define $sectionB}
	{include snippet-custom-testimonials.php, show => $post->options('testimonials')->show, options => $post->options('testimonials')}
{/define}