Add TomCat to XAMPP installation
If you are worried about your PHP folder, you can:
- Stop Apache.
- Navigate to your XAMPP installation folder.
- Copy the
php
folder in place (so you get another folder called e.g.php - Copy
. - Install Tomcat with the XAMPP installer.
- Making sure Apache is still stopped, go back to your XAMPP installation folder.
- Delete your
php
folder and renamephp - Copy
back tophp
.
You can install Tomcat separately from XAMPP. Just remember that Tomcat needs a prior installation of Java.
After the installation of Tomcat, modify its file server.xml
(located in folder tomcat_installation_path\conf
)
to change the default port number
to another number than 8080, because 8080 is used by XAMPP.
Example: Change Connector port="8080"
to Connector port="8081"
.
Now when you start XAMPP you go to localhost:8080
,
and whenever you run Tomcat you go to localhost:8081
.
You may also do it in other way round as well, keeping the default port number of Tomcat and changing XAMPP's port number.
References:
- Configure and Use Apache Tomcat
- How to change Tomcat default port ?