<div id="directory-search" class="tour-sidebar-search clearfix" data-interactive="{ifset $themeOptions->search->enableInteractiveSearch}yes{else}no{/ifset}">
	<form action="{$homeUrl}" id="dir-search-form" method="get" class="dir-searchform">
		<div id="dir-search-inputs">
			<div id="dir-holder">

				<div class="dir-holder-wrap">
					{if !empty($themeOptions->search->searchTitle)}<h3>{$themeOptions->search->searchTitle}</h3>{/if}
					<input type="text" name="s" id="dir-searchinput-text" placeholder="{__ 'Search'}" class="dir-searchinput"{ifset $isDirSearch} value="{$site->searchQuery}"{/ifset}>
					
					<input type="text" id="dir-searchinput-category" class="dir-searchinput-select first" placeholder="{__ 'Trip type'}">
					<input type="text" name="categories" id="dir-searchinput-category-id" value="0" style="display: none;">
					
					<input type="text" id="dir-searchinput-location" class="dir-searchinput-select" placeholder="{__ 'Destination'}">
					<input type="text" name="locations" id="dir-searchinput-location-id" value="0" style="display: none;">
					
					{ifset $isWidget}
					<input type="text" id="dir-searchinput-date-from" name="from" class="dir-searchinput-date first" placeholder="{__ 'From'}"{ifset $_GET['from']} value="{$_GET['from']}"{/ifset}>
					<input type="text" id="dir-searchinput-date-to" name="to" class="dir-searchinput-date" placeholder="{__ 'To'}"{ifset $_GET['to']} value="{$_GET['to']}"{/ifset}>
					<input type="text" id="dir-searchinput-price" name="price" class="dir-searchinput-price" placeholder="{__ 'Max price'} {ifset $themeOptions->directory->currency}({$themeOptions->directory->currency}){/ifset}"{ifset $_GET['price']} value="{$_GET['price']}"{/ifset}>
					{else}
					<input type="text" id="dir-searchinput-price" name="price" class="dir-searchinput-price" placeholder="{__ 'Max price'} {ifset $themeOptions->directory->currency}({$themeOptions->directory->currency}){/ifset}"{ifset $_GET['price']} value="{$_GET['price']}"{/ifset}>
					<input type="text" id="dir-searchinput-date-from" name="from" class="dir-searchinput-date first" placeholder="{__ 'From'}"{ifset $_GET['from']} value="{$_GET['from']}"{/ifset}>
					<input type="text" id="dir-searchinput-date-to" name="to" class="dir-searchinput-date" placeholder="{__ 'To'}"{ifset $_GET['to']} value="{$_GET['to']}"{/ifset}>
					{/ifset}

					{ifset $themeOptions->search->showAdvancedSearch, $isWidget}
					<div id="dir-search-advanced">
						<div class="text-geo-radius clear">
							<input class="val" type="text" name="geo-radius" id="dir-searchinput-geo-radius" value="{ifset $isGeolocation}{$geolocationRadius}{else}0{/ifset}" data-default-value="0">
							<div class="metric">km</div>
							<div class="off" style="display: none;">{_ "GEOLOCATION OFF"}</div>
						</div>
						<div class="geo-slider">
							<div class="value-slider">
								<div class="value-background"></div>
							</div>
						</div>
					</div>
					<input type="checkbox" name="geo" id="dir-searchinput-geo" class="hidden">
					<input type="hidden" name="geo-lat" id="dir-searchinput-geo-lat" value="0">
					<input type="hidden" name="geo-lng" id="dir-searchinput-geo-lng" value="0">
					{/ifset}

					<div class="reset-ajax"></div>
				</div>
			</div>
		</div>

		<div id="dir-search-button">
			{if isset($themeOptions->search->showAdvancedSearch) && !isset($isWidget)}
			<div id="dir-search-advanced">
				<div class="text-geo-radius clear">
					<input class="val" type="text" name="geo-radius" id="dir-searchinput-geo-radius" value="{ifset $isGeolocation}{$geolocationRadius}{else}0{/ifset}" data-default-value="0">
					<div class="metric">km</div>
					<div class="off" style="display: none;">{_ "GEOLOCATION OFF"}</div>
				</div>
				<div class="geo-slider">
					<div class="value-slider">
						<div class="value-background"></div>
					</div>
				</div>
			</div>
			<input type="checkbox" name="geo" id="dir-searchinput-geo" class="hidden">
			<input type="hidden" name="geo-lat" id="dir-searchinput-geo-lat" value="0">
			<input type="hidden" name="geo-lng" id="dir-searchinput-geo-lng" value="0">
			{/if}
			<input type="submit" value="{__ 'Search'}" class="dir-searchsubmit">
		</div>

		<input type="hidden" name="dir-search" value="yes" />

	</form>
</div>

{if (!isset($isDirSingle)) || ($headerType != 'map')}
	<script type="text/javascript">
	jQuery(document).ready(function($) {
		var mapNotIncluded = true;
		{include 'ajaxfunctions-javascript.php'}
	});
	</script>
{/if}