Website whatever.com has links to it with whatever.com/Widgets and whatever.com/widgets and some search engine treats these as different URLs. I want whatever.com/Widgets to be whatever.com/widgets when somebody clicks on it. How do I do this? With hundred of pages. Basically just want all to be lowercase.
Hi John, The most simple method is here: http://www.askapache.com/htaccess/rewrite-uppercase-lowercase.html. You can simply copy and paste the code from that page, and see if it will work. Note: I never have a need for this, I am sure it will work, but I do not know it this will satisfy your need (another source mention that .htaccess method will slower your server's respond). I use keywords "htaccess change uppercase to lowercase", so probably there is a better solution than that.
If you're using some kind of CMS (which I really hope you are), you could force the links being displayed, whether it's in the menu, post-links, etc. to be lower case by modding the underlying code (if it's php, strtolower() around the outputted url, for instance). However, if this isn't a CMS, that might not be ideal. Depending on the amount of links, you could do a search and replace of all that contains upper-case letters, both in the files and in the database.
If you're using some kind of CMS, particularly Wordpress: Which brings me this: https://wordpress.org/plugins/force-lowercase-urls/ it has not been updated for 2 years, thus, with all Wordpress updates it probably will work or not. Which reminds of these: https://wordpress.org/plugins/redirection/ This plugin will automatically redirect old URLs to new URLs when you change your post/page URL, and keep them in the database. It also records all 404 pages, and give an option to redirect those 404 pages to the correct page, to another page, or to homepage. Very useful. I do not remember if this plugin can automatically correct wrong URL to the correct URL (for instance, if you change UPPERCASE to lowercase prior to installing this plugin), but it is worthy to try. https://wordpress.org/plugins/search-regex/ This plugin helps you change anything you want in the database for Wordpress output. I can't remember if this plugin makes the changes directly to the tables (so, when you uninstall the plugin, the changes will stay) or if it keeps its own tables (so, when you uninstall/deactivate this plugin, the changes will be restored), but it is quite useful, too. However, the latter requires us to learn a bit about regex, which is good actually. I use it along with this tool site: https://regex101.com/ for testing.