After configuring Nginx, when accessing Tomcat, Tomcat displays such as:
From this state can be seen, guess is CSS and JS these files are not loaded.
In addition, access to the pages deployed on the Tomcat project is the same, with different nginx accesses to the project under Tomcat such as:
Through Nginx as a proxy server, access to the page is like this:
These conditions are obviously due to the server through Nginx as load balancer, unable to load the CSS and JS these files, such as this problem, through a search and find, modify the nginx nginx.conf configuration file to be displayed normally, modify the configuration as follows:
Added such a configuration for loading css,js and picture files.
In the jsp_server refers to the woolen, in fact, is the upstream configuration.
Summary: Nginx as a Load balancer server, the ability to load css,js and picture files, you need to add in the configuration file about the static file loading, that is, the configuration of the Proxy_pass property. There may be other better ways.
The above describes the Nginx do load balancer can not load css,js, including nginx, load balancing aspects of the content, I hope that the PHP tutorial interested in a friend helpful.