Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html>
- <head>
- <title>Женя лох!!1</title>
- <meta charset="utf-8">
- </head>
- <body>
- <script>
- var req = new XMLHttpRequest();
- var url = "http://localhost:8080/oauth/token?grant_type=password&username=IIvanov@gmail.com&password=password";
- req.open('POST', url, true);
- req.setRequestHeader('Authorization', 'Basic Y2xpZW50OnNlY3JldA==');
- req.send();
- req.addEventListener('load', function() {
- document.write(this.responseText);
- });
- req.addEventListener('error', function() {
- console.log(this.responseText);
- });
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement