dimanche 14 juin 2015

How to change the project URL to the last servlet called?

From a servlet "servlet.html", I can call another servlet "servlet2.html" like this:

dispatcher = getServletContext().getRequestDispatcher("/servlet2.html");

However, in the brouzer, the URL is from the first servlet:

http://localhost:8080/project/servlet.html

I would like it to be the URL of the current servlet.

http://localhost:8080/project/servlet2.html

Is that possible?

Aucun commentaire:

Enregistrer un commentaire