Have you ever thought about how to change or rename your localhost address with a domain name you like?. For me when I found that I can change localhost address to a domain.
I was so excited to use my favourite domain name, instead of localhost. Have you decided to change your Localhost name to a specific domain name?
Like many other developers and me. Here Is How to change your localhost address to your favourite domain name. Here are two easy methods to change your Windows localhost address to the domain name. Step — 1: Run your notepad or any other text editor as administrator. Here you can add your favourite domain name with the same IP address as I have added the Dev.
This technique is a little bit easier than method one. To change your localhost to domain name all you need to do is run your wamp server and go to localhost page. Copy the full contents of hosts file that we previously opened in step 3. Paste the content into the notepad file that you opened as an administrator in step 4. Click "Save As" on the new notepad. Change the directory on the Save Popup Window to the following folder:.
You will see a file on top called "hosts". Select the file and it will prompt "file already exists, do you want to override the file? Double click to open a file called "httpd-vhosts". If it asks you to choose a program to open it, choose Notepad. ServerName example. Note it must be the same domain name that you used in Step 3. Next restart your xampp.
Type in your new domainname into the browser's search bar and you are good to go. Accept them Read more about our policy privacy. Contact us. When you think of a hosts file, think of it as plain-text file used by the operating systems to map IP addresses to hostname on the local computer.
The hosts file has priority over DNS. When you type a domain name in your browser to go to a website, your computer translates the domain name your typed into an IP address and connect to the server that hosts the website. While translating the name to IP, the local hosts file is the first file your operating look at. This is how the process works. The lines starting with are comments and are ignored. The process of editing Windows 10 hosts file is simple and straightforward.
To add an entry or modify the hosts file, simply open the hosts file at the path below using Notepad or any other text editor. Changes you make to the hosts file take effect immediately. If you want to undo changes to the hosts file, simply open the file and remove the lines you added or precede the line with a to ignore it.
0コメント