Contents
Can folder names have dashes?
Naming guidelines Make file and directory names lowercase. In general, separate words with hyphens, not underscores. Use only standard ASCII alphanumeric characters in file and directory names.
Can you use a dash in a file name?
Don’t start or end your filename with a space, period, hyphen, or underline. Keep your filenames to a reasonable length and be sure they are under 31 characters. Avoid using spaces and underscores; use a hyphen instead. This will also improve your search engine rankings.
What are dashes and underscores?
Answer: Dashes. Why: As explained by Matt Cutts in the Google Webmaster Help YouTube video, dashes in the URLs are used to separate two words whereas underscores combine both words into one. In SEO terms this means that when using a dash to separate words in your URL, Google will index all of these terms individually.
Do you use underscore or dash in file names?
So it behooves us to use something other than a space in file and folder names. Historically, I’ve used underscore, but I recently discovered that the correct character to substitute for space is the dash.
Which is a word character, the dash or the underscore?
The slightly longer answer is, the underscore is traditionally considered a word character by the w regex operator. Here’s RegexBuddy matching the w operator against multiple ASCII character sets: As you can see, the dash is not matched, but underscore is.
Is it better to change URLs to dashes or underscores?
If you have an existing website that’s already doing well, don’t make such a widespread change like converting from underscores to dashes. The potential problems from changing these URLs might be worse than the potential gains from having dashes rather than underscores in them.
How are underscores and dashes treated in a text box?
I expect a text box to treat underscores and dashes like my IDEs treat them: an underscore as a letter, and a dash as “punctuation”. In programming of course, this makes sense.