Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 13
    actually you can add more than one url-pattern tag inside the servelet-mapping ;) Commented Jan 28, 2012 at 14:41
  • 5
    Servlet 2.5 and newer support multiple url-pattern tags inside servlet-mapping Commented May 22, 2012 at 12:59
  • Just be careful with index files (index.html) since they may take precedence over your servlet. Commented Dec 11, 2015 at 15:43
  • I think it's bad idea use *.sth. If somebody will get url example.com/index.jsp?g=.sth he will get the source of jsp file. Or I'm wrong? (I'm new in Java EE) I usually use url pattern /css/* and etc. Commented Jun 2, 2017 at 15:48