回答編集履歴

1

追加

2017/11/28 03:22

投稿

yambejp
yambejp

スコア114814

test CHANGED
@@ -30,6 +30,8 @@
30
30
 
31
31
  }
32
32
 
33
+ $veges=htmlspecialchars(implode("、",$vege));
34
+
33
35
  $fruit=filter_input(INPUT_POST,"fruit",FILTER_DEFAULT,$option);
34
36
 
35
37
  foreach($fruit as $val){
@@ -37,6 +39,8 @@
37
39
  $checked["fruit"][$val]=" checked=\"checked\"";
38
40
 
39
41
  }
42
+
43
+ $fruits=htmlspecialchars(implode("、",$fruit));
40
44
 
41
45
  print_r($checked);
42
46
 
@@ -74,6 +78,24 @@
74
78
 
75
79
  </form>
76
80
 
81
+ <hr>
82
+
83
+ <div class="search-result">
84
+
85
+ <h1>検索結果</h1>
86
+
87
+ <h2>野菜</h2>
88
+
89
+ <p>{$veges}</p>
90
+
91
+ <h2>フルーツ</h2>
92
+
93
+ <p>{$fruits}</p>
94
+
95
+ </div>
96
+
97
+
98
+
77
99
  eof;
78
100
 
79
101
  ?>
@@ -81,3 +103,5 @@
81
103
 
82
104
 
83
105
  ```
106
+
107
+ ※結果欄を追記しておきました