diff --git a/inc/template-functions.php b/inc/template-functions.php index 04f6705..c674a86 100644 --- a/inc/template-functions.php +++ b/inc/template-functions.php @@ -112,3 +112,25 @@ if ( ! function_exists( 'ofisuport_display_each_faq_categories' ) ) : } } endif; //end ofisuport_display_each_faq_categories + +/** + * Display search form for FAQs + */ + +if ( ! function_exists( 'ofisuport_display_faq_search' ) ) : + function ofisuport_display_faqs_search() { + // search form for category + // https://developer.wordpress.org/reference/functions/get_search_form/#comment-369 + // https://wordpress.stackexchange.com/questions/313037/restrict-a-search-to-a-custom-post-type + + echo ''; + } +endif; //end ofisuport_display_each_faq_categories diff --git a/page-templates/faqs-page.php b/page-templates/faqs-page.php index 6fbe614..284b539 100644 --- a/page-templates/faqs-page.php +++ b/page-templates/faqs-page.php @@ -44,6 +44,7 @@ get_header(); + diff --git a/search.php b/search.php index 2427d44..ca860ef 100644 --- a/search.php +++ b/search.php @@ -15,14 +15,45 @@ get_header(); + +
+ + +
+ + + + + + + + +
+ ' . get_search_query() . '' ); +?> + + + + +
" >
- ', esc_url( get_permalink() ) ), '' ); ?> + ', esc_url( get_permalink() ) ), '' ); ?>