Viewers!

I had a bit problem when working on both ASP and PHP. I had to install IIS and once finished with it, I had to uninstall it and then install XAMPP and so on…

This was a very time consuming process and also a real problem for me.
I was continuously in search of a solution for this till I found this great solution which I am also sharing with you.

How to Use both Internet Information Services and PHP (Apache) Server such as XAMPP, WAMP, AppServ or ony other PHP Server:


Through the following method I run both the servers at a single time without having any sort of problem.
Just copy my steps.

1. Install IIS on your machine. Test whether http://localhost/ is working for you and pointing you at www directory of your IIS root.

Related Post: Install IIS on Windows 7 in easy steps

2. Now install an Apache server program (Xampp, Wamp, AppServ, or Apache separately)

Now go to Apache root directory and then to conf folder.

Might be something like:
C:\xampp\apache\conf

Image

3. Open httpd.conf in any text editor (e.g Notepad)

4. Search for the text:

Listen 80

and replace it with:

0.0.0.0:8080

as shown in picture.

Image

5. Now again search for the text:

ServerName localhost:80

and replace it with:

ServerName localhost:8080

as shown in picture.

Image

6. Save the file httpd.conf and reboot your machine (system).

Thats It!!!

Now do the following to run both servers:

For IIS:

IIS


Write in your browser:
http://localhost:80/your-folder/your-file.asp
(See the Image)

For Apache:

Apache

Write in your browser:
http://localhost:8080/your-folder/your-file.php
(See the Image)

What has 80 and 8080 to do with both the Servers???

In fact, all the servers running on any machine are assigned a port to run on. And port for IIS and Apache both is 80 by default. So that is why we can not install both the servers at a single time because two servers could not have a same port at a same time.

So, by the above mentioned method you cheat your machine to recognize one server on one port and the other on the other. So enjoy the cheering.

Have any queries??? Don’t feel shy to post them here. We welcome any informative comments.

1 Comment

Leave a Reply

Your email address will not be published. Required fields are marked *