2

Some SEO audit tools reports same URL with different case as being duplicate content. In order to avoid this, I try to always use the lowercase version but some links were indexed with a different case, so what I am doing is to read the current URL and compare it with the lowercase version. If it's different I am doing a 301 redirect - using CFLOCATION tag to the lowercase version. So far so good with this exception...

enter image description here

I had to use the picture because even here I couldn't copy-paste the URL just like you see it above. Instead the paste will make it look like this:

https://gr.mynetmoto.com/shop.cfm/M%CE%BF%CF%84%CE%BF%CF%83%CF%85%CE%BA%CE%BB%CE%AD%CF%84%CE%B1-%CE%BB%CE%AC%CF%83%CF%84%CE%B9%CF%87%CE%B1.html

I am using this code to do the 301 redirect:

<cflocation url="#VARIABLES.correct_url#" statuscode="301" addtoken="no">

For the above URL's it doesn't work. Any ideas? I have tried to encode/decode the string, but no luck.

1 Answers1

4

The right way to fix this problem seems to be the replacement of CFLOCATION tag with CFHEADER

<cfheader charset="utf-8" name="location" value="#VARIABLES.correct_url#">
<cfheader statuscode="301">

Thank you for your help @Ageax