http://localhost/xampp/ "Object not found!"

Alles, was den Apache betrifft, kann hier besprochen werden.

http://localhost/xampp/ "Object not found!"

Postby JAG » 16. August 2011 20:14

Hi guys, I just added a virtual host entry in my httpd-vhosts.conf file to run my site locally:

<VirtualHost *:80>
ServerName das
ServerAdmin webmaster@das.com
DocumentRoot /Websites/das.com/public
<Directory "/Websites/das.com/public">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>

However, now when I try to use http://localhost/xampp/, it tells me Object not found!

How can I get both my new virtual host and the XAMPP setup page working correctly, without having to remove my virtual host entry and reloading Apache to be able to view the http://localhost/xampp/ page?
JAG
 
Posts: 4
Joined: 16. August 2011 19:58

Re: http://localhost/xampp/ "Object not found!"

Postby Altrea » 16. August 2011 20:36

Do you have defined a vhost entry for localhost too?
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: http://localhost/xampp/ "Object not found!"

Postby JAG » 16. August 2011 21:01

Bingo!

I went ahead and created a virtual host entry for localhost as you suggested, and it works again.

Thanks!

<VirtualHost *:80>
ServerName localhost
ServerAdmin webmaster@das.com
DocumentRoot /xampp/htdocs
<Directory "/xampp/htdocs">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
JAG
 
Posts: 4
Joined: 16. August 2011 19:58

Re: http://localhost/xampp/ "Object not found!"

Postby Altrea » 16. August 2011 21:56

You are welcome.

Just to explain:
If you use vhosts, the default entry for documentRoot are no longer active.
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: http://localhost/xampp/ "Object not found!"

Postby JAG » 16. August 2011 23:05

In which configuration file is the default entry for DocumentRoot located, btw?
JAG
 
Posts: 4
Joined: 16. August 2011 19:58

Re: http://localhost/xampp/ "Object not found!"

Postby Altrea » 16. August 2011 23:11

JAG wrote:In which configuration file is the default entry for DocumentRoot located, btw?

\conf\httpd.conf
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: http://localhost/xampp/ "Object not found!"

Postby JAG » 16. August 2011 23:27

Thank you. I completely understand why the problem happened now.
JAG
 
Posts: 4
Joined: 16. August 2011 19:58

Re: http://localhost/xampp/ "Object not found!"

Postby theking2 » 20. September 2012 16:26

I was just struggling with the same problem. It makes some sense that setting vhosts would mess with the top DocumentRoot and ServerName. What baffled me is that the localhost/phpmyadmin stays working like a breeze without a vhost connection the xampp/htdocs!

What does phpmyadmin do what xampp can't? So my question.

But thumbs up for the sollution.
theking2
 
Posts: 30
Joined: 08. March 2012 09:12
XAMPP version: latest
Operating System: W7

Re: http://localhost/xampp/ "Object not found!"

Postby Altrea » 20. September 2012 18:18

hi theking2 (there is ALWAYS time for a short salutation, especially if you are asking for help on a community board. It's a matter of politeness),

phpmyadmin is using an Alias matching for all host requests.
You can find that alias on line ~102 in your \xampp\apache\conf\extra\httpd-xampp.conf

best wishes,
Altrea

P.S.: next time please start a new thread for your question. We have a "one thread per user and problem" rule and your question is in no way related to the headline of that topic "http://localhost/xampp/ "Object not found!""
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 11926
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64


Return to Apache

Who is online

Users browsing this forum: No registered users and 11 guests