質問編集履歴
1
POSTが空の場合、NULLという処理を加えました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -13,6 +13,26 @@
|
|
13
13
|
//検索機能処理
|
14
14
|
|
15
15
|
if (!empty($_POST)) {
|
16
|
+
|
17
|
+
if ($_POST['area'] == '') {
|
18
|
+
|
19
|
+
$_POST['area'] = NULL;
|
20
|
+
|
21
|
+
}
|
22
|
+
|
23
|
+
if ($_POST['genre'] == '') {
|
24
|
+
|
25
|
+
$_POST['genre'] = NULL;
|
26
|
+
|
27
|
+
}
|
28
|
+
|
29
|
+
if ($_POST['belong'] == '') {
|
30
|
+
|
31
|
+
$_POST['belong'] = NULL;
|
32
|
+
|
33
|
+
}
|
34
|
+
|
35
|
+
|
16
36
|
|
17
37
|
$_SESSION['search'] = $_POST;
|
18
38
|
|