Daniel
Daniel

Reputation: 28

how can I redirect to a JSP from other JSP in JAVA

Hello friends how can I redirect to a JSP from other JSP ? I want to show a pdf in the browser (I have programmed the pdf in the last JSP but with the dispatcher that I use it to redirect the last jsp , the name of the last jsp doesn't appear in the browser, and I need that the name of the last JSP appears in the browser. thanks

Upvotes: 0

Views: 389

Answers (2)

Sid
Sid

Reputation: 4995

Use response.sendRedirect(), or if you want to open a pop up window, just use window.open() and pass the URL of JSP in the pop up.

Upvotes: 1

Femi
Femi

Reputation: 64700

If you need the name to appear you will need to use a client-side redirect rather than a dispatcher.

Upvotes: 0

Related Questions