質問編集履歴

1

質問修正

2018/09/25 06:45

投稿

aizawal-hiroki
aizawal-hiroki

スコア56

test CHANGED
File without changes
test CHANGED
@@ -5,6 +5,10 @@
5
5
 
6
6
 
7
7
  Failed to load https://*****.jp/++++/: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://*****.jp' is therefore not allowed access.
8
+
9
+
10
+
11
+ Cross-Origin Read Blocking (CORB) blocked cross-origin response https://*****.jp/++++/ with MIME type text/xml. See https://www.chromestatus.com/feature/5629709824032768 for more details.
8
12
 
9
13
 
10
14
 
@@ -16,11 +20,17 @@
16
20
 
17
21
  $.ajax({
18
22
 
19
- url: "https://nscvt02.admint.jp/TransUpload/getId/vkey:" + vkey
23
+ url: "https://*****.jp/++++/vkey:" + vkey
20
24
 
21
25
  ,type: 'POST'
22
26
 
23
27
  ,data : param
28
+
29
+ , xhrFields: {
30
+
31
+ withCredentials: true
32
+
33
+ }
24
34
 
25
35
 
26
36
 
@@ -40,4 +50,34 @@
40
50
 
41
51
 
42
52
 
53
+ サーバー側の問題なのはわかっていてhtaccessは下記のように記入しています
54
+
55
+
56
+
57
+ ```htaccess
58
+
59
+ <IfModule mod_rewrite.c>
60
+
61
+ RewriteEngine On
62
+
63
+ RewriteCond %{REQUEST_FILENAME} !-d
64
+
65
+ RewriteCond %{REQUEST_FILENAME} !-f
66
+
67
+ RewriteRule ^(.*)$ index.php?url=$1 [QSA,L]
68
+
69
+ RewriteCond %{HTTP:Origin} (.+)
70
+
71
+ RewriteRule . - [E=CORS_ORIGIN:%1]
72
+
73
+ Header set Access-Control-Allow-Origin %{CORS_ORIGIN}e env=CORS_ORIGIN
74
+
75
+ Header set Access-Control-Allow-Credentials true
76
+
77
+ </IfModule>
78
+
79
+ ```
80
+
81
+
82
+
43
83
  よろしくお願いします