Image help with small sized images from old oscommerce

Open to all! Ask other shopowners for help.
Post Reply
14Steve14
Senior Contributor
Posts: 923
Joined: Fri Oct 25, 2019 7:01 pm
Phoenix Version: v1.0.9.1
Has thanked: 17 times
Been thanked: 103 times

Image help with small sized images from old oscommerce

Post by 14Steve14 »

Years ago when I used to use oscommerce my site had two sizes of images. A standard sized one that showed on the products page, and a small one that was used where the code needed a small image and allowed the site to load faster. ( who remembers those days of old slow internet through a modem)

Fast forward a few years, and Phoenix is now used so no need for the small images. The small images were removed from the site many years ago as they were no longer required. I am still getting lots of errors in my error logs that images cannot be found. All these images have small in the name and have been off the site for years.

I have updated sitemaps, check the images definitely do not exist and have no idea what else to try. I have tried having google remove the images but they cannot find the images to remove. I cannot nofollow the image location in robots.txt as the image is not on the server or website.

Does anyone have an idea where are these image errors coming from?

Would switching off google imagebot from searching the site work, even if a temporary thing.

Any help welcome


Join The Code Co-op to get access to your library in the Code Co-op Forum
ecartz
Core Team
Posts: 3084
Joined: Tue Nov 05, 2019 6:02 pm
Phoenix Version:
Has thanked: 4 times
Been thanked: 208 times

Re: Image help with small sized images from old oscommerce

Post by ecartz »

14Steve14 wrote: Thu Jul 21, 2022 9:11 am I am still getting lots of errors in my error logs that images cannot be found. All these images have small in the name and have been off the site for years.
If you look in your access log (not the error log), you should see something like
123.456.78.90 - - [17/Jul/2022:05:11:03 +0000] "GET /favicon.ico HTTP/2.0" 404 196
If it's mostly the same or similar IP addresses, you might look some of them up. E.g. at https://iplocation.io/ip-whois-lookup

I'm guessing that since Google has tools to remove URLs, that it's not Google. If you have trouble reading them or want more feedback, then post a couple of those IPs here. Best to ban the correct bot if you're bot banning. Similarly, apparently webmaster tools can find what links to a URL. Again, if you post some examples here, people may have more advice.

You should be able to put a URI like

Code: Select all

Disallow: /images/small-*.jpg
in robots.txt. I'm saying jpg here, but it could be gif or something else. This still may not help, but it shouldn't hurt anything either (assuming you have no actual image names starting with small-).

If you just want the errors to go away, try using Apache's mod_rewrite to redirect /images/small-*.jpg to /images/*.jpg with a 301 (moved permanently) or 308 (permanent redirect) whenever the version without small exists.

Rainer's KISS IT Image Thumbnailer may be able to build these images on the fly. Not necessarily what you want to do, but another option.
14Steve14
Senior Contributor
Posts: 923
Joined: Fri Oct 25, 2019 7:01 pm
Phoenix Version: v1.0.9.1
Has thanked: 17 times
Been thanked: 103 times

Re: Image help with small sized images from old oscommerce

Post by 14Steve14 »

@ecartz Thanks fir the comprehensive reply.

I found lots in the access logs and the IPs are all different. Some are from Microsoft and others are unknown.

I am going to try adding a something into the robots.txt file and may also try a redirect. Both may work.

You gave this as an example

Code: Select all

Disallow: /images/small-*.jpg
Do you think something like

Code: Select all

Disallow: /images/*-small.jpg
would work as the word small is at the end of the image name. We no longer have any images in any image folder or sub folder with the _small.jpg at the end.

Here is an example of the missing image in the access logs
131.107.174.50 - - [21/Jul/2022:13:14:03 +0000] "GET /images/downloads/bsp04-small.jpg HTTP/1.1" 404 914 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:72.0) Gecko/20100101 Firefox/72.0"
ecartz
Core Team
Posts: 3084
Joined: Tue Nov 05, 2019 6:02 pm
Phoenix Version:
Has thanked: 4 times
Been thanked: 208 times

Re: Image help with small sized images from old oscommerce

Post by ecartz »

14Steve14 wrote: Thu Jul 21, 2022 1:35 pm Do you think something like

Code: Select all

Disallow: /images/*-small.jpg
would work as the word small is at the end of the image name. We no longer have any images in any image folder or sub folder with the _small.jpg at the end.
Yes, although you will have to figure out whether it is -small or _small -- that's two different things. The rules are at https://developers.google.com/search/do ... ath-values

Another possibility would be

Code: Select all

Disallow: /images/*-small.
Apparently the trailing wildcard is not needed.

If these are Microsoft IPs, you also might look up the Bing version of Google Webmaster Tools. Maybe it's there that you need to remove the URLs.
14Steve14
Senior Contributor
Posts: 923
Joined: Fri Oct 25, 2019 7:01 pm
Phoenix Version: v1.0.9.1
Has thanked: 17 times
Been thanked: 103 times

Re: Image help with small sized images from old oscommerce

Post by 14Steve14 »

Thanks very much. The actual images that they are finding have not been on the website since I last used osc 2.3.1 or what ever it was so they are very old. Gary updated the website many years ago so I am surprised that ther eis still a link to them somewhere.

I will play with the code as the images may be in any of the product categorty image folders. I will also look in Bing tools to see if there is anything in there.


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply