Page 1 of 1

Xampp Public Access

PostPosted: 23. March 2010 17:04
by rehman
Hi there,

I have just installed XAMPP. It seems to be working fine.

The problem is that instead of calling the "xampp" directory from the "htdocs" folder, I want another directory to be called,

In the "htdocs" folder which is the document root, I have 2 directories,

1. xampp
2. ABC

For e.g

If I type in my public IP

http://111.111.111.111

It takes me to xampp's home page


I want the "ABC" directory to be called


OR is there a way, by which I can disallow access to xampp completely from public IP.

Re: Xampp Public Access

PostPosted: 23. March 2010 18:00
by Nobbie
rehman wrote:If I type in my public IP

http://111.111.111.111

It takes me to xampp's home page


I want the "ABC" directory to be called


Would you like to have a visible redirection (which can be seen in the URL, like http://111.111.111.111/abc, similar to http://localhost/xampp), or would you like to show the contents of abc, without showing abc in the URL (the URL remains on http://111.111.111.111)?

rehman wrote:OR is there a way, by which I can disallow access to xampp completely from public IP.


Everything is possible, you only need to specify it more precisely. Would you like to remain the standard behaviour for localhost? And would you like to hide the xampp folder completely, when http://111.111.111.111 is entered? It means, would you like to give a "File not found" or a "Not allowed" message, if someone enters http://111.111.111.111/xampp?

Re: Xampp Public Access

PostPosted: 23. March 2010 21:50
by rehman
Let us make it simple,

If I type my public IP http://111.111.111.111,

instead of going to http://111.111.111.111/xampp, it should go to http://111.111.111.111/ABC

What do I have to do ? Any change httpd.conf ?

Re: Xampp Public Access

PostPosted: 23. March 2010 23:06
by Nobbie
You have to define two different virtualhosts (one for 127.0.0.1, one for 111.111.111.111), supply two different DocumentRoots, and in the DocumentRoot of 111.111.111.111 you have to put an index.php, which redirects to ABC (similar to the index.php of localhost, which redirects to Xampp instead of ABC).

Re: Xampp Public Access

PostPosted: 24. March 2010 04:35
by MC10
Please rename the current index.php and index.html files to index.off.php and index.off.html (or similar), then create your own index.php.