80 Setup Domain Name For Localhost Update

Change localhost to domain name in window ad your favorite domain name method two.
Setup domain name for localhost. In ubuntu the local server by default is referred by the name localhost. To change your localhost to domain name all you need to do is run your wamp server and go to localhost page. If you are using debian linux.
It s possible to set up your own domain name that happens to resolve to 127 0 0 1 and get a certificate for it using the dns challenge. Alternatively search for iis manger in start window. This technique is a little bit easier than method one.
Setting up a custom domain name instead of a localhost will help you when testing of many things such as redirecting a non www to a www website or vice versa or redirecting from http to https before publishing a website to the production hosting environment. See the section in the red box in the image above. Each line must begin with the address 127 0 0 1 this is the localhost address after the ip address type the name of the domain you wish to redirect to this address.
Right below the line 127 0 0 1 localhost enter your domain name information. If your custom domain name matches with an existing website your browser will open the localhost instead of the website while your local server is running. Now you need to configure the home page for your custom domain.
However this is generally a bad. Open iis click win r enter inetmgr in the dialog and click ok. You may only enter 1 name per line.
And depending on your windows setup you might need to be logged in as an administrator to modify the hosts file. Left click on the wamp icon in the notification area and click on www directory. However you can also create a custom domain name for you local server instead of using localhost this article explains the process to create your own custom domain name instead of using localhost here hackdx md is created as our domain which can be taken as per need.