質問編集履歴
1
コードをマークダウンにしました
title
CHANGED
File without changes
|
body
CHANGED
@@ -13,14 +13,14 @@
|
|
13
13
|
index.php:150 errorThrown : Unexpected token ポ in JSON at position 0
|
14
14
|
|
15
15
|
### 該当のソースコード
|
16
|
-
|
16
|
+
index.php
|
17
|
+
```ここに言語を入力
|
17
18
|
<?php
|
18
19
|
require_once '../../../app/config/config.php';
|
19
20
|
|
20
21
|
$get_time=date('Y/m/d H:i:s');
|
21
22
|
|
22
23
|
|
23
|
-
|
24
24
|
?>
|
25
25
|
|
26
26
|
<!DOCTYPE html>
|
@@ -229,13 +229,13 @@
|
|
229
229
|
$.ajax({
|
230
230
|
url: './select.php',
|
231
231
|
type: "POST",
|
232
|
-
dataType: "
|
232
|
+
dataType: "text",
|
233
233
|
crossDomain: false,
|
234
234
|
data: customer_id
|
235
235
|
|
236
236
|
|
237
237
|
}).done(function(data){
|
238
|
-
|
238
|
+
console.log(data);
|
239
239
|
|
240
240
|
// console.log(Array.isArray(data));
|
241
241
|
|
@@ -270,10 +270,10 @@
|
|
270
270
|
|
271
271
|
</body>
|
272
272
|
</html>
|
273
|
+
```
|
273
274
|
|
274
|
-
|
275
|
-
|
276
|
-
|
275
|
+
select.php
|
276
|
+
```ここに言語を入力
|
277
277
|
<?php
|
278
278
|
// error_log("error log test. output to file(test.log)\n",3,"./test.log");
|
279
279
|
// $json = file_get_contents('php://input');
|
@@ -281,7 +281,7 @@
|
|
281
281
|
// $_POST['customer_id'] = 1;
|
282
282
|
|
283
283
|
|
284
|
-
|
284
|
+
echo "<pre>";var_dump($_POST);echo "</pre>";
|
285
285
|
// exit;
|
286
286
|
if(isset ($_POST)){
|
287
287
|
echo "ポストが来きてる";
|
@@ -323,6 +323,7 @@
|
|
323
323
|
|
324
324
|
//json形式でindex.phpへバックする
|
325
325
|
echo json_encode($project_list);
|
326
|
+
```
|
326
327
|
### 試したこと
|
327
328
|
console.logでエラーメッセージを出力
|
328
329
|
|