I developing one website like quikr.com. In mysite i list out city list then while click the city its goes to subdomain like cityname.mywebsite.com. so how to achieve this using javascript. so share your ideas and suggestions.