[RESOLVED]Does it matter in a MVC wev app, if the folder name is lower case or upper case?

Hi,

I want to double-check on this so I don’t mess anything up…

I’m working on a MVC3 web app, which already has a folder "CSS" under the root directory. Now we just got a new UI design, which comes with "css" under the root directory, which contains some new .css files that need to be added to the application.

Can I just copy+paste the new .css files over from the "css" folder to "CSS" folder?

Reason being: the new design has taken a long time to tweek; so I’m told to keep it "Exactly" as it is given to me. However, I do not think that I can add another folder under root "css", when there is already a "CSS" folder under root.

Or should I rename the existing "CSS" to be "css"? if I do that, do I need to change it in the existing code? or it will be considered the same as "CSS"?

I just need a confirmation on: if the folder name is "CSS"; and a file "mystyle.css" is under "CSS/" folder; and another file calls for "css/mystyle.css", will it be able to access this file?

Any input is appreciated.

Thanks,

Claudia

claudia888

Or should I rename the existing "CSS" to be "css"? if I do that, do I need to change it in the existing code? or it will be considered the same as "CSS"?

If you have a folder called "CSS" in a particular location, Windows will not allow you to create another folder with the same name, irrespective of case. However, Unix-based operating systems will allow it because they are case-sensitive. URLs are not supposed
to be case-sensitive, but the reality is that some unix-based systems do not conform to this recommendation.

URLs in general are case-sensitive (with the exception of machine names). There may be URLs, or parts of URLs, where case doesn’t matter, but identifying these may not be easy. Users should always consider that URLs are case-sensitive. 

http://www.w3.org/TR/WD-html40-970708/htmlweb.html

In summary, the answer to the question in the title of your post is No (if you are working in a Windows environment).

claudia888

if the folder name is "CSS"; and a file "mystyle.css" is under "CSS/" folder; and another file calls for "css/mystyle.css", will it be able to access this file?

both "CSS" and "css" are same (case insensitive). You will not run into any problems :)

Leave a Reply