We got a new magento project which was developed by another web development company and it wasn't finished. Client didn't have admin details but he had FTP details. He didn't know about control panel url, so couldn't access phpMyadmin. Instead of going back and forth with client about details, I wrote this code, so I could create admin user myself and access the admin.
I think it will be a good idea to create new admin user for every single admin user including developers, so if one developer quits we can just delete the user and don't need to worry about changing passwords again and again.
Magento by default doesn't use 301 permanent redirection when redirecting website from non-www to www or www to non-www. It instead uses 302 temporary move. If you are looking for SEO benefit or get higher rankings on google, always use www or non-www version of your website otherwise your website will be penalize by google search engine, bing search engine and others as well.
So, how can you configure your website to use 301 permanent redirect instead of 302 temporary move?