Search code examples
apachemod-rewritemod-jk

Apache mod_jk not loading CSS


I am using linux server with CentOS 7,Apache 2.4.23 with mod jk installed. mod jk is installed and configured properly which opens the site but its not loading the css of that site.

I have tried various rewrite rules too but the problem remains same.

below are the configurations which I have used in my httpd.conf for mod_jk

RewriteRule ^/(.*)$ /test/$1 [PT]

JkMount /* test

worker.properties:

worker.list=test 

worker.test.type=ajp13 
worker.test.host=localhost 
worker.test.port=8009 

all mod_jk configurations are in httpd.conf and CSS is in Tomcat

no any changes has been made in context file of Tomcat.

server.xml

shutdown port = 8005
http port = 8080
ajp port = 8009

Thanks


Solution

  • Add all your html, images and css folders in apache server and your java classes in tomcat/webapps/project/WEB-INF/classes and all will start working fine