How can I set where IntelliJ looks for files referenced in a JSP? If I have
it cannot resolve directory foo.
It looks like Settings > Web Contexts deals with this, but when I go there, it says
No web directories found
解决方案
You should configure a web facet in your project settings, then configure the directory containing foo as a "Web Resource Directory". If this is your root directory, set the "Path Relative to Deployment Root" to /.
See the official doc for more info.