-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsearchform.php
More file actions
33 lines (29 loc) · 868 Bytes
/
searchform.php
File metadata and controls
33 lines (29 loc) · 868 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
/**
* Search form template
*
* @package Yivic_Lite
*/
$yivic_search_id = esc_attr( uniqid( 'yivic-lite-header-search-' ) );
?>
<form
role="search"
method="get"
class="yivic-lite-search-form"
action="<?php echo esc_url( home_url( '/' ) ); ?>"
>
<label class="screen-reader-text" for="<?php echo $yivic_search_id; ?>">
<?php esc_html_e( 'Search for:', 'yivic-lite' ); ?>
</label>
<input
id="<?php echo $yivic_search_id; ?>"
type="search"
name="s"
class="yivic-lite-search-form__field"
value="<?php echo esc_attr( get_search_query() ); ?>"
placeholder="<?php esc_attr_e( 'Search…', 'yivic-lite' ); ?>"
/>
<button type="submit" class="yivic-lite-search-form__submit screen-reader-text">
<?php esc_html_e( 'Search', 'yivic-lite' ); ?>
</button>
</form>