warrentang Posted January 9, 2009 Share Posted January 9, 2009 Hi I have a Windows 2003 Sever on which I need to use IIS and Apache at the same time. The server has a single public IP address. What I want to achieve is, for example, when I input www.myaspnet.com I want it to open a ASP.NET website in IIS on my server; when I use www.myphp.com, I want to open a PHP website in Apache on the same server. But IIS and Apache cannot listen to the same port 80, can they? And I don't want to let either of them listen to another port, because I would have to use addresses like www.myphp.com:8080, whose suffix(:8080) is not acceptable to me. How can I achieve that? Thank you for your time and enthusiasm. Regards Warren Quote Link to comment Share on other sites More sharing options...
JonnoTheDev Posted January 9, 2009 Share Posted January 9, 2009 Then you cant do it because 2 applications cannot listen on the same port number Quote Link to comment Share on other sites More sharing options...
PFMaBiSmAd Posted January 9, 2009 Share Posted January 9, 2009 You would need to have your DNS redirect port 80 traffic for one of the domains to the actual port your server for that domain is using. See the "Port 80 Redirection" item at this link - http://www.no-ip.com/services/managed_dns/plus_features.html Quote Link to comment Share on other sites More sharing options...
warrentang Posted January 10, 2009 Author Share Posted January 10, 2009 Hi PFMaBiSmAd Thanks for your reply. I like the idea, but I don't have control over the DNS server and I really don't want to maintain a DNS server myself. There may be some other ways to do the same. For example, suppose I get a "transmitter" or something, which will listen to port 80; if it found the host name is www.myphp.com, it will redirect the request to Apache who is listening 8080; if it finds the name is www.myaspnet.com, it will redirect the request to IIS who is listening 9090. I need a "transmitter" (or redirector) but I don't like a DNS server. Is there any alternative? Thanks. Regards Warren Quote Link to comment Share on other sites More sharing options...
BMurtagh Posted January 14, 2009 Share Posted January 14, 2009 Hello, Can I ask why you do not want to run PHP under Windows? It is possible to do so with PHP running as an ISAPI. The reason I ask is that because if its not a necessity to run PHP on Apache, you could probably setup a host-header for the php website on your Windows box and just have it read the files from there in which case it would run under the same/current IP. Quote Link to comment Share on other sites More sharing options...
wcoleman Posted January 26, 2009 Share Posted January 26, 2009 Hey, It would be easier to just run PHP on IIS. The performance has greatly improved with PHP build 5.2.6 or higher and is a lot more stable using FastCGI (versus ISAPI). FastCGI is available for IIS 6 (built in with IIS 7) and you can get the latest version of PHP for Windows at http://windows.php.net. You can also find 'how to' guides for using PHP on Windows and other tips here - http://www.iis.net/php Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.