Forum Moderators: phranque

Message Too Old, No Replies

access forbidden error 403

no index document...?

         

Gabby7

8:21 pm on Sep 8, 2010 (gmt 0)

10+ Year Member



Hello+
Thank you in advance for any guidance you can provide...I'm not sure this is the correct forum...I have installed xampp for windows version 1.7.2; I'm using windows xp and DW CS4; I have purchased a book on "dw cs4 w/css, ajax, & php" and in attempting to follow the directions for creating a site in dw (located on the testing server, xampp) I have lost access!?! When I go to

[localhost...]

all I get is (or when I try to F12 to view my site when in DW, the same screen comes up):

Access forbidden!
You don't have permission to access the requested directory. There is either no index document or the directory is read-protected.

If you think this is a server error, please contact the webmaster.

Error 403
localhost
9/8/2010 11:56:10 AM
Apache/2.2.12 (Win32) DAV/2 mod_ssl/2.2.12 OpenSSL/0.9.8k mod_autoindex_color PHP/5.3.0 mod_perl/2.0.4 Perl/v5.10.0


I do not know what I've done to block my access; I do not know if it is something I did when defining the site in DW or if I messed up something in xampp. I am a novice with xampp, so any instructions need to be in very basic terms and very detailed on what to do & where to do it...Thank you.

jdMorgan

9:35 pm on Sep 8, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You've lost access to what? Was there another "Web site" previously defined on your machine? Sorry, that's just not clear.

The error message is fairly specific: Try creating a very-simple 'hello world' index.html page (static HTML) and putting it in the defined DocumentRoot of the 'new' web site. That should take care of the "no index document" problem, at least for debugging purposes. And of course, check the file permissions, and make sure that that DocumentRoot filepath is "readable" by Apache as a "user."

Also, look at the server error log file -- at the path defined for it in the server configuration file.

I don't know if more detail will help, but if the server is configured with "Options -Indexes" and no index file exists, then the result of a request for the index URL will always be a 403-Forbidden response.

It should be clear that even though you've got some so-called "plug and play" software packages here, that does not mean that you won't need to know and understand all of the details of your server configuration. After all, now it's just you seeing the server error message... What if a minor problem occurs later and it's one of your users/customers seeing that message, and following the instructions in that message (contact the Webmaster)? Be prepared... Some nice info and tutorials at apache.org, BTW. :)

Jim

SteveWh

9:38 pm on Sep 8, 2010 (gmt 0)

10+ Year Member



Instead of ...localhost/, try entering the actual page name: localhost/page.htm (whatever). If that works but localhost/ doesn't, it probably means you have indexing turned off. If you request a folder (like localhost/) and the folder doesn't contain an index.html, index.htm, or index.php file, Apache by default displays an automated index of the folder contents. If you have that option turned off (disallowed), it generates a 403 Forbidden error.

Look in .htaccess or httpd.conf or other Apache config file for
Options -Indexes
and change it to
Options +Indexes

Another possible cause relates to user permissions such as if you created your website in a folder owned by one Windows user but the folder is defined as completely private so no other users can read the files in it. So, for example, Apache would have been installed as your Windows Administrator user account, and it must be launched under that account. But if your website files are within My Documents of another user's account and that user's profile is private, then Apache can't read it. The solution in that case is to move your website out of any user's My Documents and into a location that all Windows users can access, such as something like C:\xampp\Apache2\htdocs\yoursite.

[simultaneous post with jdMorgan]

Gabby7

10:48 pm on Sep 8, 2010 (gmt 0)

10+ Year Member



Thank you for the quick replies. I am well aware that there is a lot I need to learn about testing servers, PHP, etc. I will research all that both of you have written about and attempt to figure out what I did wrong...