Google Answers Logo
View Question
 
Q: Apache mod_rewrite image redirect ( No Answer,   2 Comments )
Question  
Subject: Apache mod_rewrite image redirect
Category: Computers > Internet
Asked by: sun818-ga
List Price: $2.00
Posted: 30 Dec 2002 22:27 PST
Expires: 31 Dec 2002 08:20 PST
Question ID: 135342
I currently have image files removed from my web site to conserve
space. Instead of editing the static HTML file, I want to use
.htaccess to redirect missing images files to a default image file. My
reasoning is that in the future, I may upload those missing pictures
again.

So, if I have HTML that says: <img
src="http://domain.com/images/blue-widget.gif"> and the file is
missing, it would instead redirect the image and load the default
image, http://domain.com/images/default-image.gif
(err.. I assume the static HTML would not change?)

Thanks,
Sun818

p.s. I am looking for specific code that I can plug into my .htaccess
Answer  
There is no answer at this time.

Comments  
Subject: Re: Apache mod_rewrite image redirect
From: samrolken-ga on 31 Dec 2002 02:23 PST
 
What you are aiming to do would be possible. You could have your
standard 404 error page be a PHP script that can rewrite out an image
if that's what was missing. However, speaking as a Google Answers
Researcher, I would note that this information is a bit more valuable
than the $2.00 you have as the list price.
Subject: Re: Apache mod_rewrite image redirect
From: sun818-ga on 31 Dec 2002 08:19 PST
 
Then don't answer it.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy