Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $.ajax({
- type: 'POST',
- url: 'http://dev.leed.steko.com.ua/api/takedata-promo',
- crossDomain: true,
- data: $(this).serialize(),
- dataType: 'json',
- success: function(data) {
- console.log(data)
- },
- error: function (responseData, textStatus, errorThrown) {
- alert('POST failed.');
- }
- });
- header('Access-Control-Allow-Origin: '.$_SERVER['HTTP_ORIGIN']);
- header('Access-Control-Allow-Methods: GET, PUT, POST, DELETE, OPTIONS');
- header('Access-Control-Max-Age: 1000');
- header('Access-Control-Allow-Headers: Content-Type, Authorization, X-Requested-With');
Add Comment
Please, Sign In to add comment