Forum Moderators: open

Message Too Old, No Replies

Upper case URI and lower case URI

duplicate content issues

         

tonynoriega

4:24 pm on Mar 5, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



ok, dont hit me...

prior to my arrival there was no standards in place for directory or file name development...

so on my CMS application, Teamsite, i have all kinds of mixed case file names, directories..etc...

/This_Directory/
/that-directory/
/evenThisDirectory/

what i am noticing in my G Webmaster Tools is that this is getting dinged as 2 separate pages:

/Med/mp_20210.aspý
/med/mp_20210.aspý

it SHOULD be the Capitalized directory /Med/ but someone can type lower case and it resolves just as well.

is there an IIS setting that i shoudl request be put into place to keep URI's the case that they are?

can IIS be config'd to serve only lower case?
which im not sure i want to do, since half of my directories have upper case and mixed case type files...

not sure how to handle this.

carguy84

2:29 am on Mar 8, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hmm, does your server block header checks or something? Google should be smart enough to read the webserver variant and know whether or not case matters.

BTW, worst implementation ever of a file system = linux. Lower case/Upper case = different version. oiy.

g1smd

2:48 am on Mar 8, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



In Apache, asking for a URL but with some characters in the wrong case correctly generates a 404 error. The characters and casing have to exactly match to see the content.

In IIS you can change the casing of any of the characters and the same content is served with status "200 OK". That is not desirable behaviour as it creates infinite Duplicate Content.

You should maybe aim for all lower-case in your URLs and 301 redirect all other variants. Look to fix www/non-www issues in the same redirect too.

pageoneresults

3:21 am on Mar 8, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Take g1smd's advice and force all lower case, you'll be much safer that way and you'll have less headache to deal with in the long term. You cannot do this via IIS from what I understand. You're going to need a third party application like ISAPI_Rewrite to force lower case via a httpd.ini file (Version 2.0) or .htaccess file (Version 3.0).

For Version 2.0 (httpd.ini), these rules force lower case...

#Convert all UPPER CASE to lower case
RewriteCond URL ([^?]+[[:upper:]][^?]*).*
RewriteHeader X-LowerCase-URI: .* $1 [CL]

RewriteCond Host: (.+)
RewriteCond X-LowerCase-URI: (.+)
RewriteRule [^?]+(.*) http\://$1$2$3 [I,RP]

tonynoriega

3:30 pm on Mar 9, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



that seems like the solution i need.. a few follow up Q's if i may...

why do i need a third party tool? could i just not create a .txt file with the above mentioned rules and rename the file, and place it at the root of the website on the server?

again, this is not a hosting company, i have access to our web servers.

the rules of the httpd.ini file will affect all current upper case directories and files, as well as any new ones that may arrise right?

darrenG

4:46 pm on Mar 10, 2009 (gmt 0)

10+ Year Member



THe third party tool is a filter that plugs itself into IIS and handles requests as set out in the config files. It is the engine, without it the text file would do nothing.

tonynoriega

5:23 pm on Mar 10, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Ah, i understand.