How to forward the requestdispatcher to a remote URL

后端 未结 3 2134
遥遥无期
遥遥无期 2021-01-03 02:15

Am having a HTML page http://www.mywebapp.com/sample.html which is used from remote server. am passing the HTML URL as hidden form like this in the same HTML fo

3条回答
  •  情歌与酒
    2021-01-03 02:43

    You can't forward a request to a URL which is external to your webapp. You probably want to send a redirect to this URL instead. See HttpServletResponse.sendRedirect().

    See Difference between JSP forward and redirect

提交回复
热议问题