<?php
/**
 * Sets up the actual search form
 * @package tweaker5
 */
?>

<?php

global $next_id; ++$next_id; ?>

<div class="search">
	
	<form method="get" class="searchform" id="search-form<?php if ( $next_id ) echo '-' . $next_id; ?>" action="<?php echo esc_url( home_url()); ?>/">
		
		<div>
			<input class="searchtext" type="text" name="s" id="searchtext<?php if ( $next_id)  echo '-' . $next_id; ?>" value="<?php if ( is_search() ) echo esc_attr( get_search_query() ); else _e( 'Search this site...', 'tweaker5' ); ?>" onfocus="if(this.value==this.defaultValue)this.value='';" onblur="if(this.value=='')this.value=this.defaultValue;" />
			<input style="display:none;" class="searchsubmit" name="submit" type="submit" id="searchsubmit<?php if ( $next_id ) echo '-' . $next_id; ?>" value="<?php _e( 'Search', 'tweaker5' ); ?>" />
		</div>
	
	</form>

</div><?php // close .search ?>