Tuesday, October 20, 2009

Changing PORT number in XAMMP

if you are on windows, open C:\Program Files\Apache Software Foundation\Apache2.2\conf and look for a file called httpd.conf. In that file, find the following section

#
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
#
#Listen 12.34.56.78:80
Listen 80

Simply change the number after the word Listen to the port you want it to use. Save the file and restart Apache. Be aware though that you will have to reconfigure any firewalls and routers to forward requests to your new port. Also, some people may have problems accessing your website if it is not on port 80 or the alternative 8080.

No comments:

Post a Comment