Answer the question
In order to leave comments, you need to log in
Client not getting response from server REST, JAVA?
There is this form:
<form name="user" action="POST">
Email: <input name="email" required type="email" />
Password: <input name="password" required type="password" />
Login:<input name="login" required type="text">
<input type="submit" value="Submit" onclick="registration()" />
</form>
var xhr = new XMLHttpRequest();
function registration()
{
xhr.open("GET", "http://localhost:8080/user/login", true);
xhr.send();
success: alert('Succes');
}
@GET
@Path("/register")
@Consumes({MediaType.APPLICATION_JSON})
@Produces({MediaType.APPLICATION_JSON})
String user_info(@PathParam("email") String email, @PathParam ("password") String password ) throws FileNotFoundException{
return "succes";
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question