/ means root?

Problems with the Windows version of XAMPP, questions, comments, and anything related.

/ means root?

Postby 04nunhucks » 08. March 2007 08:17

hi, newbie here

When I use / in htaccess, apache looks for C:/.htpasswd
if I try this: htaccess/.htpasswd, it looks for C:/xampp/apapche/htaccess/.htpasswd.

I need / to mean the root the root so I can have /htaccess/.htpasswd.

How do I do this?
04nunhucks
 
Posts: 4
Joined: 08. March 2007 08:13

Postby Wiedmann » 08. March 2007 13:29

I need / to mean the root the root

And that's what you have:
When I use / in htaccess, apache looks for C:/.htpasswd

"/" is the root of your filesystem. And if Apache is installed on drive c it's the root directory "c:/".

(In this directive you have a normal filesystem access)
Wiedmann
AF Moderator
 
Posts: 17102
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby 04nunhucks » 08. March 2007 13:53

but how do I get to the root of the website i.e. htdocs?
04nunhucks
 
Posts: 4
Joined: 08. March 2007 08:13

Postby Wiedmann » 08. March 2007 13:56

but how do I get to the root of the website i.e. htdocs?

?
(just look in the "httpd.conf" what you have configured as DocumentRoot)
Wiedmann
AF Moderator
 
Posts: 17102
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby WorldDrknss » 10. March 2007 11:38

When creating .htaccess files you use the full path.
Try:
C:/xampp/apapche/htdocs/.htpasswd. or /xampp/apapche/htdocs/.htpasswd
http://wdguides.org/gusion.php?name=gen ... hehtaccess

example htaccess:
Code: Select all
AuthUserFile /xampp/xampp/htdocs/.htpasswd
AuthGroupFile /dev/null
AuthName "Password Protected Area"
AuthType Basic

<limit GET POST>
require valid-user
</limit>

example htpasswd:
Code: Select all
test:$apr1$Mb1.....$sGSccCGmLldDhfL79QK/W1
http://wdguides.org - XAMPP Tutorials & MORE!!!!
User avatar
WorldDrknss
 
Posts: 292
Joined: 17. September 2005 13:40

Postby 04nunhucks » 18. March 2007 16:43

Aha, right thanks.
04nunhucks
 
Posts: 4
Joined: 08. March 2007 08:13


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 131 guests