<Solved>could not load jpg, gif files.

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

<Solved>could not load jpg, gif files.

Postby hanpedro » 11. July 2009 03:54

could not load jpg, gif files.

I installed xampp for windows 1.7.1 and tried to load my web page.
But I could not see only x-marks for jpgs and gifs.

Phpmyadmin shows same.

Any comment would be appreciated.
Last edited by hanpedro on 12. July 2009 15:46, edited 1 time in total.
hanpedro
 
Posts: 133
Joined: 09. February 2005 06:03
Operating System: SCientific Linux 6.1 x86

Re: could not load jpg, gif files.

Postby Wiedmann » 11. July 2009 09:57

There is something in the XAMPP for Windows FAQ about images and style sheets not loading.
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Re: could not load jpg, gif files.

Postby hanpedro » 11. July 2009 12:09

Wiedmann,

I've read it, and tried as follows.
1) activating
2) deactivating
EnableMMAP off
EnableSendfile off


However still it is not browsing pictures.

But jpg link of this server brows picture.
http://192.168.0.2/test/test.jpg

Wiedmann wrote:There is something in the XAMPP for Windows FAQ about images and style sheets not loading.
hanpedro
 
Posts: 133
Joined: 09. February 2005 06:03
Operating System: SCientific Linux 6.1 x86

Re: could not load jpg, gif files.

Postby TazzyT » 11. July 2009 23:28

I had this same problem and have pulled a lot of hair but I figured it out. Maybe this will help you as well.

I was trying to view a local copy of a clients site and couldnt view any images. The css file loaded but not the images from the css file. Eventually I noticed the sites that would not display images contained a copy of the online sites .htaccess file and the sites that would display did not have the onlines .htaccess file. I deleted my local copy of the .htaccess file as the local site is for testing only (no public access), refreshed the page, and all my images appeared.

In your local site folder look for a .htaccess file. Here you have 2 options:

1) delete the local .htaccess (local only) file (best option if site is only a local copy for testing)

2) look for similar in your .htaccess file and either comment it out or delete it:

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://sitename.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://sitename.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.sitename.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.sitename.com$ [NC]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp|zip)$ - [F,NC]

Now if I could only get all those hours back and replace all the pulled out hair! Good luck and hope this helps!
TazzyT
 
Posts: 1
Joined: 11. July 2009 23:17

Re: could not load jpg, gif files.

Postby hanpedro » 12. July 2009 15:45

Thanks a lot!!

Solved.
hanpedro
 
Posts: 133
Joined: 09. February 2005 06:03
Operating System: SCientific Linux 6.1 x86


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 83 guests