.HTACCESS: Server Redirect

XML, Perl, Python, and other languages can be discussed here, even if it isn't PHP (We might forgive you).

Moderator: General Moderators

Post Reply
Quazel
Forum Commoner
Posts: 25
Joined: Thu Mar 18, 2010 7:12 pm
Location: Edina, Minnesota

.HTACCESS: Server Redirect

Post by Quazel »

Is their a mod_rewrite or any other .htaccess function to do this?

A client side script references the image:

Code: Select all

http://www.example.com/re/direct/image.jpg
And the mod_rewrite sees that and redirects the query to:

Code: Select all

http://www.example.com/here/now/image.jpg
The limitations:
If the file is accessed from a browser the actual url doesn't change but gets just the contents.
Their is no physical file their its just the .htaccess working its magic.
Must work with different files like:
A client side script references the image:

Code: Select all

http://www.example.com/re/direct/image3.jpg
And the mod_rewrite sees that and redirects the query to:

Code: Select all

http://www.example.com/here/now/image3.jpg
Quazel
Forum Commoner
Posts: 25
Joined: Thu Mar 18, 2010 7:12 pm
Location: Edina, Minnesota

Re: .HTACCESS: Server Redirect

Post by Quazel »

Anyone?
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Re: .HTACCESS: Server Redirect

Post by s.dot »

Yes, you can do it with mod_rewrite.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
Quazel
Forum Commoner
Posts: 25
Joined: Thu Mar 18, 2010 7:12 pm
Location: Edina, Minnesota

Re: .HTACCESS: Server Redirect

Post by Quazel »

Can you be more specific on the expression to do that?
Post Reply