projects
/
WP-Themes
/
PrestonFeather.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
879922a
)
Check isset for searchType in functions.php
author
Laury GvR
<laury@gaslightmedia.com>
Fri, 19 Dec 2014 17:34:00 +0000
(12:34 -0500)
committer
Laury GvR
<laury@gaslightmedia.com>
Fri, 19 Dec 2014 17:34:00 +0000
(12:34 -0500)
functions.php
patch
|
blob
|
history
diff --git
a/functions.php
b/functions.php
index
93d45a7
..
530e5e5
100755
(executable)
--- a/
functions.php
+++ b/
functions.php
@@
-34,9
+34,11
@@
function glm_page_menu($parent = 0, $class = '')
function SearchFilter($query) {
- $searchType = $_GET["searchType"];
- if ($searchType == 'blog') {
- $query->set('post_type', 'post');
+ if(isset($_GET['search-type'])) {
+ $searchType = $_GET['searchType'];
+ if ($searchType == 'blog' && !is_admin()) {
+ $query->set('post_type', 'post');
+ }
}
return $query;
}