Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
Showing
1 changed file
with
3 additions
and
1 deletions
@@ -39,9 +39,11 @@ class ListController extends WebAction | @@ -39,9 +39,11 @@ class ListController extends WebAction | ||
39 | 'rowNum' => FILTER_VALIDATE_INT, | 39 | 'rowNum' => FILTER_VALIDATE_INT, |
40 | 'page' => FILTER_VALIDATE_INT), false); | 40 | 'page' => FILTER_VALIDATE_INT), false); |
41 | //字符转码 | 41 | //字符转码 |
42 | - foreach($condition as $key => $val){ | 42 | + if (!empty($condition)) { |
43 | + foreach ($condition as $key => $val) { | ||
43 | $condition[$key] = rawurldecode($val); | 44 | $condition[$key] = rawurldecode($val); |
44 | } | 45 | } |
46 | + } | ||
45 | //性別(频道) | 47 | //性別(频道) |
46 | $gender_cookie = !isset($_COOKIE['_Gender']) ? '3' : ($_COOKIE['_Gender']=='2,3' ? 2 : 1); | 48 | $gender_cookie = !isset($_COOKIE['_Gender']) ? '3' : ($_COOKIE['_Gender']=='2,3' ? 2 : 1); |
47 | $gender = $this->get('gender') ? ($this->get('gender') == '2,3' ? 2 : 1) : $gender_cookie ; | 49 | $gender = $this->get('gender') ? ($this->get('gender') == '2,3' ? 2 : 1) : $gender_cookie ; |
-
Please register or login to post a comment