JS code
<html>
<head>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script>
$.getJSON("http://localhost:8080/gbsshop/rest/auth/test/xyz?callback=?", function (data) {
alert("52");
});
</script>
</head>
</html>
REST Easy method
@GET
@POST
@Path("/test/{param}")
@Produces({MediaType.APPLICATION_JSON })
public String returnMessage(@PathParam("param") String msg) {
System.out.println("~~~~~~~~~~~~~"+msg+"~~~~~~~~~~~~");
return "HEllo "+msg;
}
I see that the server gets the call but the browser fails with "Uncaught SyntaxError: Unexpected Identifier"
Any help is appreciated. Thanks for the time.