Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var data = null;
- var xhr = new XMLHttpRequest();
- xhr.withCredentials = true;
- xhr.addEventListener("readystatechange", function () {
- if (this.readyState === 4) {
- console.log(this.responseText);
- }
- });
- xhr.open("GET", "https://emall13.xarx.rocks/wp-json/xarx/custom-order");
- xhr.setRequestHeader("Authorization", "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvZW1hbGwxMy54YXJ4LnJvY2tzIiwiaWF0IjoxNTc1NTY4OTcwLCJuYmYiOjE1NzU1Njg5NzAsImV4cCI6MTU3NjE3Mzc3MCwiZGF0YSI6eyJ1c2VyIjp7ImlkIjoiMjk4In19fQ.n_uqp-5T_hRG3KYpEnkKpBLkn_CztdCjstf90guy56I");
- xhr.send(data);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement