projects
/
WP-Plugins
/
michsci-products.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2eb6689
)
testing search function with cookie
author
Anthony Talarico
<talarico@gaslightmedia.com>
Fri, 29 Jan 2016 17:38:09 +0000
(12:38 -0500)
committer
Anthony Talarico
<talarico@gaslightmedia.com>
Fri, 29 Jan 2016 17:38:09 +0000
(12:38 -0500)
index.php
patch
|
blob
|
history
diff --git
a/index.php
b/index.php
index
e2a37bc
..
7e2c6ab
100644
(file)
--- 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();
}