<div class="flexslider slideshow">
	<ul class="slides">
		<li><img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/images/slideshow-image1.jpg" alt=""></li>
		<li><img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/images/slideshow-image2.jpg" alt=""></li>
		<li><img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/images/slideshow-image3.jpg" alt=""></li>
	</ul><!-- /.slides -->

	<div class="slideshow-caption">
		<h1><?php __('ws_slideshow_caption');?></h1>

		<p><?php __('ws_slideshow_caption_desc');?></p>
		
		<div class="buttons">
			<?php
			if($tpl['option_arr']['o_website_seo'] == 'No')
			{ 
				?>
				<a href="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjWebsite&amp;action=pjActionYachts&amp;listing_search=1&amp;for=sale" class="btn btn-secondary"><?php __('ws_btn_yachts_for_sale');?></a>
	
				<a href="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjWebsite&amp;action=pjActionYachts&amp;listing_search=1&amp;for=rent" class="btn btn-secondary"><?php __('ws_btn_yachts_for_rent');?></a>
				<?php
			}else{
				?>
				<a href="yachts-for-sale.html" class="btn btn-secondary"><?php __('ws_btn_yachts_for_sale');?></a>
	
				<a href="yachts-for-rent.html" class="btn btn-secondary"><?php __('ws_btn_yachts_for_rent');?></a>
				<?php
			} 
			?>
		</div><!-- /.buttons -->
	</div><!-- /.slideshow-caption -->
</div><!-- /.flexslider -->

<div class="find">
	<form<?php echo $tpl['option_arr']['o_website_seo'] == 'Yes' ? ' action="'.PJ_INSTALL_URL.'index.php"' : NULL;?> id="pjYlQuickSearch" name="pjYlQuickSearch" method="get" class="form-horizontal">
		<input type="hidden" name="controller" value="pjWebsite" />
		<input type="hidden" name="action" value="pjActionYachts" />
		<input type="hidden" name="listing_search" value="1" />
		<input type="hidden" name="for" value="rent" />
		<input type="hidden" name="min_price" value="0" />
		<input type="hidden" name="max_price" value="500000" />
		<div class="container">
			<h2><?php __('ws_search_for_yachts');?></h2>

			<div class="row">
				<div class="col-md-2">
					<div class="btn-group" role="group" aria-label="...">
						<button type="button" class="btn btn-default pjYlSearchType" data-type="sale"><?php __('ws_menu_for_sale');?></button>
						<button type="button" class="btn btn-default pjYlSearchType active" data-type="rent"><?php __('ws_menu_for_rent');?></button>
					</div>
				</div><!-- /.col-md-2 -->

				<div class="col-md-3 col-sm-6">
					<label class="control-label"><?php __('ws_search_manufacturer');?>:</label>
					
					<div class="form-control-select">
						<select name="manufacturer_id">
							<option value="">-- <?php __('ws_option_all');?> --</option>
							<?php
							foreach($tpl['manufacturer_arr'] as $v)
							{
								?><option value="<?php echo $v['id']?>"><?php echo $v['name']?></option><?php
							} 
							?>
						</select>
					</div><!-- /.form-control-select -->
				</div><!-- /.col-md-3 -->

				<div class="col-md-3 col-sm-6">
					<label class="control-label"><?php __('ws_search_model');?></label>
								
					<div class="form-control-select">
						<select name="listing_model">
							<option value="">-- <?php __('ws_option_all');?> --</option>
							<?php
							foreach($tpl['model_arr'] as $v)
							{
								?><option value="<?php echo $v['listing_model']?>"><?php echo $v['listing_model']?></option><?php
							} 
							?>
						</select>
					</div><!-- /.form-control-select -->
				</div><!-- /.col-md-3 -->

				<div class="col-md-2 col-sm-6">
					<label class="control-label"><?php __('ws_search_price');?>:</label>
					
					<div class="range clearfix">
						<div id="pjYlQuickPriceSlider" style="margin-top: 10px;"></div>
						<?php
						$price_from = pjUtil::formatCurrencySign(0, $tpl['option_arr']['o_currency']);
						$price_to = pjUtil::formatCurrencySign(500000, $tpl['option_arr']['o_currency']);
						?>
						<p>
							<span id="pjAcPriceLabel" data-currency="<?php echo $tpl['option_arr']['o_currency']; ?>"><?php echo $price_from;?> - <?php echo $price_to;?></span>
						</p>
					</div><!-- /.range -->
				</div><!-- /.col-md-3 -->

				<div class="col-md-2 col-sm-6">
					<button type="submit" class="btn btn-primary btn-block"><?php __('ws_search');?></button>
				</div><!-- /.col-md-1 -->
			</div><!-- /.row -->
		</div><!-- /.container -->
	</form>
</div><!-- /.find -->
<?php
if(!empty($tpl['sale_feature_arr']))
{ 
	?>
	<div class="section section-secondary">
		<div class="container">
			<h2><?php __('ws_featured_yachts_for_sale');?></h2>
	
			<div class="yachts">
				<div class="row">
					<?php
					foreach($tpl['sale_feature_arr'] as $v)
					{ 
						$image = NULL;
						if(!empty($v['image']))
						{
							if(is_file(PJ_INSTALL_PATH . $v['medium_image']))
							{
								$image = PJ_INSTALL_URL . $v['medium_image'];
							}
						}
						$price = pjUtil::formatCurrencySign(number_format($v['listing_price'], 0, '.', ','), $tpl['option_arr']['o_currency']);
						
						$listing_title = pjSanitize::html(stripslashes($v['title']));
						if ($tpl['option_arr']['o_website_seo'] == 'No')
						{
							$url = $_SERVER['SCRIPT_NAME'] . '?controller=pjWebsite&amp;action=pjActionView&amp;id=' . $v['id'] .(isset($_GET['iframe']) ? '&amp;iframe' : NULL);
						} else {
							$path = str_replace('\\', '/', dirname($_SERVER['SCRIPT_NAME']));
							$path = $path == '/' ? '' : $path;
							$url = $path .'/'. $controller->friendlyURL($v['title']) . "-". $v['id'] . ".html";
						}
						?>
						<div class="col-sm-4">
							<a href="<?php echo $url;?>" class="yacht">
								<div class="yacht-head">
									<div class="yacht-title"><?php echo $listing_title;?></div><!-- /.yacht-title -->
		
									<div class="yacht-price"><?php echo $price;?></div><!-- /.yacht-price -->
								</div><!-- /.yacht-head -->
		
								<div class="yacht-body">
									<img src="<?php echo $image;?>" alt="">
		
									<div class="yacht-body-overlay">
										<ul>
											<?php
											if(!empty($v['listing_year']))
											{ 
												?><li><span><?php __('ws_listing_year');?>:</span> <?php echo $v['listing_year'];?></li><?php
											}
											if(!empty($v['listing_loa']))
											{
												?><li><span><?php __('ws_listing_loa');?>:</span> <?php echo $v['listing_loa'];?></li><?php
											}
											if(!empty($v['listing_beam']))
											{
												?><li><span><?php __('ws_listing_beam');?>:</span> <?php echo $v['listing_beam'];?></li><?php
											}
											$enum_arr = __('enum_arr', true);
											if(!empty($v['listing_length']))
											{
												?><li><span><?php __('ws_listing_length');?>:</span> <?php echo pjSanitize::html($v['listing_length']);?> <?php echo $enum_arr[$tpl['option_arr']['o_length']];?></li><?php
											}
											if(!empty($v['listing_power']))
											{
												?><li><span><?php __('ws_listing_power');?>:</span> <?php echo pjSanitize::html($v['listing_power']);?> <?php echo $enum_arr[$tpl['option_arr']['o_power']];?></li><?php
											} 
											?>
										</ul>
									</div><!-- /.yacht-body-overlay -->
								</div><!-- /.yacht-body -->
							</a><!-- /.yacht -->
						</div><!-- /.col-sm-4 -->
						<?php
					} 
					?>
				</div><!-- /.row -->
			</div><!-- /.yachts -->
		</div><!-- /.container -->
	</div><!-- /.section -->
	<?php
}
if(!empty($tpl['rent_feature_arr']))
{ 
	?>
	<div class="section">
		<div class="container">
			<h2><?php __('ws_featured_yachts_for_rent');?></h2>
	
			<div class="yachts">
				<div class="row">
					<?php
					foreach($tpl['rent_feature_arr'] as $v)
					{ 
						$image = NULL;
						if(!empty($v['image']))
						{
							if(is_file(PJ_INSTALL_PATH . $v['medium_image']))
							{
								$image = PJ_INSTALL_URL . $v['medium_image'];
							}
						}
						$price = '';
						if($v['min_price'] != '' || $v['max_price'] != '')
						{
							if($v['min_price'] == $v['max_price'])
							{
								$price = pjUtil::formatCurrencySign(number_format($v['min_price'], 0, '.', ','), $tpl['option_arr']['o_currency']) . ' ' . __('front_per_week', true);
							}else{
								$price = pjUtil::formatCurrencySign(number_format($v['min_price'], 0, '.', ','), $tpl['option_arr']['o_currency']) . ' - ' . $price = pjUtil::formatCurrencySign(number_format($v['max_price'], 0, '.', ','), $tpl['option_arr']['o_currency']) . ' ' . __('front_per_week', true);
							}
						}
						$listing_title = pjSanitize::html(stripslashes($v['title']));
						if ($tpl['option_arr']['o_website_seo'] == 'No')
						{
							$url = $_SERVER['SCRIPT_NAME'] . '?controller=pjWebsite&amp;action=pjActionView&amp;id=' . $v['id'] .(isset($_GET['iframe']) ? '&amp;iframe' : NULL);
						} else {
							$path = str_replace('\\', '/', dirname($_SERVER['SCRIPT_NAME']));
							$path = $path == '/' ? '' : $path;
							$url = $path .'/'. $controller->friendlyURL($v['title']) . "-". $v['id'] . ".html";
						}
						?>
						<div class="col-sm-4">
							<a href="<?php echo $url;?>" class="yacht">
								<div class="yacht-head">
									<div class="yacht-title"><?php echo $listing_title;?></div><!-- /.yacht-title -->
		
									<div class="yacht-price"><?php echo $price;?></div><!-- /.yacht-price -->
								</div><!-- /.yacht-head -->
		
								<div class="yacht-body">
									<img src="<?php echo $image;?>" alt="">
		
									<div class="yacht-body-overlay">
										<ul>
											<?php
											if(!empty($v['listing_year']))
											{ 
												?><li><span><?php __('ws_listing_year');?>:</span> <?php echo $v['listing_year'];?></li><?php
											}
											if(!empty($v['listing_loa']))
											{
												?><li><span><?php __('ws_listing_loa');?>:</span> <?php echo $v['listing_loa'];?></li><?php
											}
											if(!empty($v['listing_beam']))
											{
												?><li><span><?php __('ws_listing_beam');?>:</span> <?php echo $v['listing_beam'];?></li><?php
											}
											if(!empty($v['listing_length']))
											{
												?><li><span><?php __('ws_listing_length');?>:</span> <?php echo pjSanitize::html($v['listing_length']);?> <?php echo $enum_arr[$tpl['option_arr']['o_length']];?></li><?php
											}
											if(!empty($v['listing_power']))
											{
												?><li><span><?php __('ws_listing_power');?>:</span> <?php echo pjSanitize::html($v['listing_power']);?> <?php echo $enum_arr[$tpl['option_arr']['o_power']];?></li><?php
											} 
											?>
										</ul>
									</div><!-- /.yacht-body-overlay -->
								</div><!-- /.yacht-body -->
							</a><!-- /.yacht -->
						</div><!-- /.col-sm-4 -->
						<?php
					} 
					?>
				</div><!-- /.row -->
			</div><!-- /.yachts -->
		</div><!-- /.container -->
	</div><!-- /.section -->
	<?php
} 
?>

<div class="section section-background">
	<div class="container">
		<h2><?php __('ws_what_we_offer');?></h2>

		<div class="offers">
			<div class="row">
				<div class="col-sm-4">
					<div class="offer">
						<div class="offer-icon">
							<img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/css/images/ico-1.png" alt="">
						</div><!-- /.offer-icon -->

						<h3><?php __('ws_offer_heading_1');?></h3>

						<p><?php __('ws_offer_desc_1');?></p>
					</div><!-- /.offer -->
				</div><!-- /.col-sm-4 -->

				<div class="col-sm-4">
					<div class="offer">
						<div class="offer-icon">
							<img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/css/images/ico-2.png" alt="">
						</div><!-- /.offer-icon -->
						
						<h3><?php __('ws_offer_heading_2');?></h3>

						<p><?php __('ws_offer_desc_2');?></p>
					</div><!-- /.offer -->
				</div><!-- /.col-sm-4 -->

				<div class="col-sm-4">
					<div class="offer">
						<div class="offer-icon">
							<img src="<?php echo PJ_INSTALL_URL . PJ_TEMPLATE_PATH . basename(dirname(__FILE__));?>/css/images/ico-3.png" alt="">
						</div><!-- /.offer-icon -->
						
						<h3><?php __('ws_offer_heading_3');?></h3>

						<p><?php __('ws_offer_desc_3');?></p>
					</div><!-- /.offer -->
				</div><!-- /.col-sm-4 -->
			</div><!-- /.row -->

			<p class="buttons">
				<?php
				if($tpl['option_arr']['o_website_seo'] == 'No')
				{ 
					?>
					<a href="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjWebsite&amp;action=pjActionServies" class="btn btn-primary"><?php __('ws_view_services');?></a>
					<?php
				}else{
					?>
					<a href="services.html" class="btn btn-primary"><?php __('ws_view_services');?></a>
					<?php
				} 
				?>
			</p><!-- /.buttons -->
		</div><!-- /.offers -->
	</div><!-- /.container -->
</div><!-- /.section -->

<div class="section">
	<div class="container">
		<h2><?php __('ws_menu_about_us')?></h2>

		<div class="row">
			<div class="col-sm-6">
				<div class="entry">
					<h4><?php __('ws_who_we_are');?></h4>

					<p><?php __('ws_who_we_are_desc');?></p>
					<?php
					if($tpl['option_arr']['o_website_seo'] == 'No')
					{ 
						?>
						<p><a href="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjWebsite&amp;action=pjActionAboutUs"><?php __('ws_read_more');?></a></p>
						<?php
					}else{
						?>
						<p><a href="about-us.html"><?php __('ws_read_more');?></a></p>
						<?php
					} 
					?>
				</div><!-- /.entry -->
			</div><!-- /.col-sm-6 -->

			<div class="col-sm-6">
				<div class="entry">
					<h4><?php __('ws_our_locations');?></h4>

					<p><?php __('ws_our_locations_desc');?></p>

					<?php
					if($tpl['option_arr']['o_website_seo'] == 'No')
					{ 
						?>
						<p><a href="<?php echo $_SERVER['PHP_SELF']; ?>?controller=pjWebsite&amp;action=pjActionAboutUs"><?php __('ws_read_more');?></a></p>
						<?php
					}else{
						?>
						<p><a href="about-us.html"><?php __('ws_read_more');?></a></p>
						<?php
					} 
					?>
				</div><!-- /.entry -->
			</div><!-- /.col-sm-6 -->
		</div><!-- /.row -->
	</div><!-- /.container -->
</div><!-- /.section -->