+ found_posts.' results matching "' . $query . '" found.'; + ?> +
+-
+
+
+
+
- + + + +
diff --git a/css/index.css b/css/index.css
index 32f761e..84a6ae5 100644
--- a/css/index.css
+++ b/css/index.css
@@ -19,6 +19,7 @@
@import "pagination";
@import "title";
@import "archive";
+@import "search-result";
:root {
--color-black: #000;
diff --git a/css/search-result.css b/css/search-result.css
new file mode 100644
index 0000000..9f55ce3
--- /dev/null
+++ b/css/search-result.css
@@ -0,0 +1,28 @@
+.search-result {
+ margin-bottom: var(--space-sm);
+}
+
+.search-result__head,
+.search-result__body,
+.search-result__title {
+ margin-bottom: var(--space-xs);
+}
+
+.search-result__metadata {
+ color: var(--color-grey);
+ font-size: 12px;
+}
+
+.search-result__icon,
+.search-result__text {
+ display: inline-block;
+ vertical-align: middle;
+}
+
+.search-result__icon {
+ height: 16px;
+}
+
+.search-result__text {
+ margin: 0 15px 0 5px;
+}
diff --git a/theme/functions.php b/theme/functions.php
index d171c45..5aeb900 100644
--- a/theme/functions.php
+++ b/theme/functions.php
@@ -76,3 +76,11 @@ function windycoys_share_twitter_url() {
$link = get_the_permalink();
echo $url . urlencode($title . ': ' . $link . ' by @WindyCOYS');
}
+
+function windycoys_search_posts_per_page($query) {
+ if ($query->is_search) {
+ $query->set( 'posts_per_page', '10' );
+ }
+ return $query;
+}
+add_filter('pre_get_posts', 'windycoys_search_posts_per_page');
diff --git a/theme/icons.php b/theme/icons.php
index ae3364d..16f6b76 100644
--- a/theme/icons.php
+++ b/theme/icons.php
@@ -23,6 +23,9 @@
Sorry, there is no article to display
+ found_posts.' results matching "' . $query . '" found.';
+ ?>
+
+
+
+
+
+
+ Sorry, no results found.
+