我在REST Java Server方面有以下内容,但我得到了
Redirect was blocked for CORS request
如何解决这个问题?
@POST
@Path("/details")
public void findDetails(@FormParam("productName")
String productName, @Context
HttpServletRequest request, @Context
HttpServletResponse response) {
URI location = new java.net.URI("http://www.google.com");
if (productName != null) {
return Response.temporaryRedirect(location).build();
}
}
答案 0 :(得分:1)
不应该
Web\Configurations
是
productName != null
或重命名为
userid != null