Questions tagged as 'servlet'

0
answers

Problem to return to jsp by changing url using sendRedirect in servlet

I log in to my jsp, then I command the servlet to do the checks, and return to jsp, but when I return the url it continues with the path of the servlet, not with my index.jsp, it follows part of the code which return to my jsp. try {...
asked by 24.03.2017 / 18:10
1
answer

URI Rest with HttpServlet

So, I'm developing a mini framework for study purposes, using the pattern front controller in java, and I came across the following problem. First of all, I'll explain how it works. I embedded the jetty server inside the framework, when I...
asked by 02.03.2017 / 02:51
2
answers

Date Formatting in Java and Hibernate

Good morning everyone! I'm trying to return a formatted date, it's in the database as date, but for return it could be a msm string. Some friends have indicated two modes, creating a new method for formatting or using java 1.8's LocalDate. The...
asked by 16.01.2017 / 11:38
0
answers

request.getRequestDispatcher is not working and has no errors

I have a problem in the request.getRequestDispatcher ("Valida.jsp"). forward (request, response); from my servlet that does not forward to the Valida.jsp page. I need to pass from an HTML to a javascript (by Ajax) which passes the infos to a S...
asked by 30.12.2016 / 04:23
1
answer

How to display a confirmation message after checking in the servlet?

Good afternoon everyone! When I click the Change button, I check to see if the data in the database remains the same. How do I return a confirmation window if the results are not the same? Example: I select the material I want to change, fill...
asked by 13.11.2016 / 19:34
1
answer

SimpleDateFormatt write with empty field

I'm having trouble writing an empty field because it's being formatted with SimpleDateFormatt .. Writing the console generates an error java.text.ParseException: Unparseable date: "" Servlet private void gravarProximo(HttpSer...
asked by 14.11.2016 / 04:02
0
answers

500 error in servlet instantiation

Hello. I'm trying to make a servlet, but tomcat does not find this servlet class. The error is:    HTTP Status 500 - Error instantiating servlet class server.PrimeiraQuestao ------------------------------------ ----------------------------...
asked by 05.11.2016 / 15:24
0
answers

Submit html form to a servlet

I made a connection with mysql and am making crud on own java . I want to use html and send to java to do crud . From what I read, you need a% of%. I tried to, but I could not. Here are the codes: Connection c...
asked by 27.09.2016 / 20:58
0
answers

ERROR attempts to retrieve data in the JSP

Error: org.apache.jasper.JasperException: An exception occurred processing JSP page /ViewAluno/index.jsp at line 20 17: 18: <body> 19: 20: <input type="text" value="<%=aluno.getId()%>"> 21: 22: <inp...
asked by 06.06.2016 / 09:32
2
answers

JSP information for another JSP

Example: I have a JSP A, which has some information and a button. When you press this button, JSP A sends variables to B (like id, name ...). B would use this information and refresh the page without redirecting. Is there any way to do this?   ...
asked by 08.04.2016 / 03:05