Error 403 Forbidden loading images

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

Error 403 Forbidden loading images

Postby rumba2012 » 02. February 2012 07:41

Hi guys,

I have this problem and I don't know how to solve it. I already checked in this forum some answer but don't work.
I installed XAMPP 1.7.7 and then I configured the virtuahost file like this : one for xampp and one for my website sample1. Then i add them on host file and all work.
The problem is that I receive 403 error when sample1 website wants to load some images.

How can I solve it ?
I tried to insert <Directory ... > in sample1 virtualhost but doesn't work. Maybe I wrong syntax.

Thanks for the help

<VirtualHost *:80>
##ServerAdmin postmaster@dummy-host2.localhost
DocumentRoot "C:/xampp/htdocs"
ServerName localhost
##ErrorLog "logs/dummy-host2.localhost-error.log"
##CustomLog "logs/dummy-host2.localhost-access.log" combined
</VirtualHost>

<VirtualHost *:80>
##ServerAdmin postmaster@dummy-host2.localhost
DocumentRoot "C:/xampp/htdocs/sample1"
ServerName sample1
ServerAlias sample1.comx
##ErrorLog "logs/dummy-host2.localhost-error.log"
##CustomLog "logs/dummy-host2.localhost-access.log" combined

<Directory "C:/xampp/htdocs/sample1">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>


In log-file there is written (one of them)
...
[Thu Feb 02 16:54:43 2012] [error] [client 127.0.0.1] (OS 5)Accesso negato. : file permissions deny server access: C:/xampp/htdocs/sample1/img/new-ribbon.png, referer: http://sample1.comx/
...
rumba2012
 
Posts: 2
Joined: 02. February 2012 07:25
Operating System: windows 7

Re: Error 403 Forbidden loading images

Postby Altrea » 02. February 2012 19:21

Hi rumba2012,

Have you restarted your Apache after you added the <Directory>-part in your vhost file?
Changes on Apache config files are just taken effect after a restart of the Apache.

best wishes,
Altrea
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: 8299
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 10 Pro x64

Re: Error 403 Forbidden loading images

Postby rumba2012 » 02. February 2012 22:09

Hi Altrea, thank for you reply ..

Oh yes, i did it. I really don't know why it doesn't work yet ..
rumba2012
 
Posts: 2
Joined: 02. February 2012 07:25
Operating System: windows 7

Re: Error 403 Forbidden loading images

Postby Grafica » 21. February 2012 21:26

Please see "Re: can't access new site folders in htdocs." The folder containing the images might be encrypted. Right-click the folder or file you want to decrypt, and then click Properties. Click the General tab, and then click Advanced. Clear the Encrypt contents to secure data check box, click OK, and then click OK again.
Grafica
 
Posts: 12
Joined: 08. February 2012 23:03
Operating System: Windows 7 SP1, 32 bit


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 34 guests