Notifications
Clear all
BugOverflow
1
Posty
1
Users
0
Reactions
1,396
Widok
0
06/11/2018 1:51 pm
Topic starter
ajax, jquery
1 Answer
0
06/11/2018 1:52 pm
Topic starter
1. add to .htaccess
1 |
Header set Access-Control-Allow-Origin "*" |
Header set Access-Control-Allow-Origin "*"
2.
1 2 3 4 5 6 7 8 9 10 11 |
$(document).ready(function () { $.ajax ({ type: 'POST', url: 'https://moodle.my.site.com/login/logout.php', data: {sesskey: "MY_METHOD_TO_GET_SESSION_KEY()"}, xhrFields: { withCredentials: true } }); }); |
$(document).ready(function () { $.ajax ({ type: 'POST', url: 'https://moodle.my.site.com/login/logout.php', data: {sesskey: "MY_METHOD_TO_GET_SESSION_KEY()"}, xhrFields: { withCredentials: true } }); });