我正在制作这样的网址
url = new URL("http","localhost",9080,"/path/to/my/resource/myAction.action");
而不是制作网址:
http://localhost:9080/path/to/my/resource/myAction.action
提出要求:
http://www.localhost.com/path/to/my/resource/myAction.action
答案 0 :(得分:1)
试试这个:
url = new URL("http://localhost:9080/path/to/my/resource/myAction.action");