Quantcast
Channel: SCN: Message List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 9165

Re: Problem in enabling CORS with Hana SPS6

$
0
0

Hi Thomas,

 

I just got the jquery ajax call to work, inserting table data via my xsjs service, jquery ajax called modified as below:

 

 

jQuery.ajax({

                                                url:jURL,

                                                jsonpCallback: 'processJSON',

                                                dataType: 'jsonp',

                                                data: {msg : msg},

                                                type: 'GET',

                                                headers : {"Access-Control-Allow-Origin" : "*"},

                                                crossDomain: true,

                                                success: function(result) { console.log(result); },

                                                error: function() { console.log('Failed!'); }

                                         });

 

 

Note the type = GET (I don't think this matters from the point of view of successful xsjs service execution whether this is POST or GET?). 

 

Also I am prompted for basic authentication with my user name/password on first call to service, even though I have updated my .xsaccess file removing the basic authentication entry (I did not restart my AWS instance as I was using a spot instance).

 

Thus it works at the moment, however I would like to remove the authentication so imagine this can be done by configuring the anonymous service.

 

Many thanks.


Viewing all articles
Browse latest Browse all 9165

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>