From ed08147cc2003c613c80bc671e7991ac04390e27 Mon Sep 17 00:00:00 2001 From: Anthony Talarico Date: Fri, 29 Jan 2016 12:38:09 -0500 Subject: [PATCH] testing search function with cookie --- index.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/index.php b/index.php index e2a37bc..7e2c6ab 100644 --- a/index.php +++ b/index.php @@ -464,6 +464,13 @@ function michsci_shortcode($atts) michsci_list_categories($cat_id); } else if ( !$catid_id && !$product_id ) { $text_query = $_REQUEST['tsearch']; + if(isset($_REQUEST['tsearch'])){ + echo $text_query; + setcookie("test", "cool",time()+1, "/" ); + } else { + setcookie("test", "null",time()+1, "/" ); + } + michsci_list_products($text_query); michsci_list_categories(); } -- 2.17.1