hi i have this ajax function
mainUrl = "http://someURL/POSMobileConnector/";
parameter = "Event Materials";
servEntity = "Product/"
console.log("test");
$.ajax({
url: mainUrl + servEntity + 'loaditembycategory/',
type: "GET",
data: parameter ,
dataType:'json',
contentType: "application/json; charset=utf-8",
ProcessData:false,
//username:"admin",
//password:"admin",
//beforeSend : function(xhr) {
// xhr.setRequestHeader("Authorization", cred/*"Basic " + encodeBase64(credentials)*/);
//},
success: function (msg) {//On Successfull service call
ServiceSucceeded(msg);
},
error: function(error){
console.log(error);
}
});
My Question is when i look at firebug. the url result is http://url/service/Product/loaditembycategory/?Event%20Materials. Now i want to remove the “?” part because the right url is to be http://url/service/Product/Event%20Materials only.
Then add it to the URL
The data param is for GET or POST params only.