Redirecting image files

ISAPI_Rewrite is Apache mod_rewrite compatible URL rewriter for Microsoft IIS
User avatar
Posts: 2
Joined: 24 Jul 2014, 06:35

Redirecting image files

24 Jul 2014, 06:44

Hi,

I have 400+ jpg images in a folder that are causing errors in Google WMT because they have spaces. I've renamed the images, replacing the spaces with underscores, but have no idea how to add a rewrite rule that forces the URL to go to the new file.

The folder structure is <domain>/admin/photos/large/. So, for example, I'd like <domain>/admin/photos/large/keep net.jpg to get redirected to <domain>/admin/photos/large/keep_net.jpg.

Can anyone help? I can do basic redirects but this one has me stumped.

Cheers

User avatar
Posts: 871
Joined: 12 Mar 2012, 09:54

Re: Redirecting image files

24 Jul 2014, 07:48

Hello,

Please try the following rule:

RewriteBase /
RewriteRule ^admin/photos/large/keep\ net\.jpg$ /admin/photos/large/keep_net.jpg [NC,R=301,L]

User avatar
Posts: 2
Joined: 24 Jul 2014, 06:35

Re: Redirecting image files

24 Jul 2014, 11:16

Perfect - thank you very much indeed!

Cheers

User avatar
Posts: 5
Joined: 14 Sep 2017, 23:30

Re: Redirecting image files

14 Sep 2017, 23:39

If u need a free photoshop alternative that give you a productive solution, photoshop online will be a great option. A free photos edit includes all the basic features as well as the extra bells and whistles that most people need to photoshop and enhance their photos and images.

Return to ISAPI_Rewrite 3.0

Who is online

Users browsing this forum: No registered users and 17 guests