teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

6

2018/11/16 15:06

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -22,13 +22,8 @@
22
22
  review.js:182 textStatus : error
23
23
  review.js:183 errorThrown : undefined
24
24
 
25
- #### CDN
26
- ```script
27
- <script src="//ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
28
- ```
29
-
30
25
  #### ソースコード
31
- ```Cakephp
26
+ ```Controller/Sample/Sample1.php
32
27
 
33
28
  <?php
34
29
  namespace App\Controller\Sample;
@@ -86,7 +81,7 @@
86
81
 
87
82
  ```
88
83
 
89
- ```js
84
+ ```webroot/js/sample1.js
90
85
 
91
86
  $("button").on("click",function(){
92
87
  var test = "test";

5

追記

2018/11/16 15:06

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -115,4 +115,10 @@
115
115
  console.log("errorThrown : " + errorThrown.message);
116
116
  });
117
117
  }
118
- ```
118
+ ```
119
+
120
+ #### 追記
121
+ - cakephpのインストールと設定
122
+ 参考サイト
123
+ [https://qiita.com/YoshikiNakamura/items/bcceaaa3d064a08233c1](https://qiita.com/YoshikiNakamura/items/bcceaaa3d064a08233c1)
124
+ [https://www.ritolab.com/entry/59](https://www.ritolab.com/entry/59)

4

文章修正

2018/11/16 13:02

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -5,6 +5,7 @@
5
5
  #### 環境
6
6
  cakephp 3.6
7
7
  jquery 3.1.1
8
+ MAMP 5.0.1
8
9
 
9
10
  #### できないこと
10
11
  以下ソースでjavascriptからajaxでコントローラにデータを渡してそれをそのままjavascriptに返しているのですが、403エラーになってしまう

3

文章修正

2018/11/16 12:45

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -38,10 +38,7 @@
38
38
  use Cake\Error\ExceptionRenderer;
39
39
 
40
40
  /**
41
- * Review Controller
41
+ * Sample1 Controller
42
- *
43
- *
44
- *
45
42
  */
46
43
  class Sample1Controller extends AppController
47
44
  {

2

文章修正

2018/11/16 11:08

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -28,7 +28,6 @@
28
28
 
29
29
  #### ソースコード
30
30
  ```Cakephp
31
- Controller/Sample/Sample1/loading
32
31
 
33
32
  <?php
34
33
  namespace App\Controller\Sample;

1

文章修正

2018/11/16 11:05

投稿

oroshitaruuuuu
oroshitaruuuuu

スコア25

title CHANGED
File without changes
body CHANGED
@@ -31,7 +31,7 @@
31
31
  Controller/Sample/Sample1/loading
32
32
 
33
33
  <?php
34
- namespace App\Controller\Netflix;
34
+ namespace App\Controller\Sample;
35
35
 
36
36
  use App\Controller\AppController;
37
37
  use Cake\ORM\TableRegistry;
@@ -42,9 +42,9 @@
42
42
  * Review Controller
43
43
  *
44
44
  *
45
- * @method \App\Model\Entity\Review[]|\Cake\Datasource\ResultSetInterface paginate($object = null, array $settings = [])
45
+ *
46
46
  */
47
- class ReviewController extends AppController
47
+ class Sample1Controller extends AppController
48
48
  {
49
49
  /**
50
50
  * Initialize method