質問編集履歴
1
初期のソースコードを記載しました
test
CHANGED
File without changes
|
test
CHANGED
@@ -79,3 +79,87 @@
|
|
79
79
|
|
80
80
|
|
81
81
|
Laravel Framework 8.30.1
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
ブラウザはchromeを使っております
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
### 補足情報
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
configディレクトリ直下cors.phpファイルです。
|
94
|
+
|
95
|
+
初期状態では以下のようになっております
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
<?php
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
return [
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
/*
|
108
|
+
|
109
|
+
|--------------------------------------------------------------------------
|
110
|
+
|
111
|
+
| Cross-Origin Resource Sharing (CORS) Configuration
|
112
|
+
|
113
|
+
|--------------------------------------------------------------------------
|
114
|
+
|
115
|
+
|
|
116
|
+
|
117
|
+
| Here you may configure your settings for cross-origin resource sharing
|
118
|
+
|
119
|
+
| or "CORS". This determines what cross-origin operations may execute
|
120
|
+
|
121
|
+
| in web browsers. You are free to adjust these settings as needed.
|
122
|
+
|
123
|
+
|
|
124
|
+
|
125
|
+
| To learn more: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS
|
126
|
+
|
127
|
+
|
|
128
|
+
|
129
|
+
*/
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
'paths' => ['api/*', 'sanctum/csrf-cookie'],
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
'allowed_methods' => ['*'],
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
'allowed_origins' => ['*'],
|
142
|
+
|
143
|
+
|
144
|
+
|
145
|
+
'allowed_origins_patterns' => [],
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
'allowed_headers' => ['*'],
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
'exposed_headers' => [],
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
'max_age' => 0,
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
'supports_credentials' => false,
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
];
|