Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var GN_URL = 'http://localhost:8080/geonetwork';
- testUsersInfo();
- testUserGet(1);
- testUserGet(2);
- function testUsersInfo(){
- Ext.Ajax.request({
- url : GN_URL + '/srv/spa/xml.info?type=users', method: 'GET',
- headers : {
- "Content-Type" : "application/xml"
- },
- success : function(response) {
- console.log(response.responseText);
- },
- failure : function(response) {
- console.log(response);
- }
- });
- }
- function testUserGet(userid){
- Ext.Ajax.request({
- url : GN_URL + '/srv/spa/xml.user.get', method: 'POST', xmlData: '<request><id>' + userid + '</id></request>',
- headers : {
- "Content-Type" : "application/xml"
- },
- success : function(response) {
- console.log(response.responseText);
- },
- failure : function(response) {
- console.log(response.responseText);
- }
- });
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement