Domain Name System (DNS): Can you change a local website url to anything.com on your network?
-
How can I change a local website like 192.168.1.100/~username/index.html to a custom url for people on my network (http://example.com) or something to that effect.
-
Answer:
Are you using Apache? If you are, you can add a virtual host to your httpd.conf file. I'd suggest reading the docs for virtual hosts and how to configure Apache for it. It's pretty straight forward. Essentially, an Apache virtual host figures out which directory to pull files from based on the information in the HTTP host: header. Below is a snippet from my httpd.conf file. <VirtualHost *:80> ServerAdmin DocumentRoot /var/www/html/processor ServerName processor ErrorLog logs/processor-error_log CustomLog logs/processor-access_log common </VirtualHost> These are all the fields you need. The first line says listen on any IP address and on port 80. ServerAdmin is used on any Apache error pages as contact. DocumentRoot is where the files are for the website. Each site has it's own DocumentRoot, normally ServerName is the hostname for this virtual host. ErrorLogs points to your custom error log file. One per virtual host. CustomLogs points to your access logs, one per host. Set all that up and restart your web server. If all goes well, you have a virtual host. But wait, there's more! You have to configure your DNS to point to your ServerName to your web server IP address. Do that however you configure your DNS. Or you can edit your .hosts file /etc/hosts on linux, %system%\system32\drivers\etc\hosts on Windows. You can have as many virtual hosts as you want. I am pretty sure you can do something similar in Windows. In fact, I think I have, but I don't recall how.
Mike Fratto at Quora Visit the source
Other answers
DNS record processor IN CNAME real-namehttp://.dummy-host-example.com. The period after com is needed.
Alan Cohen
Related Q & A:
- Can i change a regular phone into a smartphone? if i can how?Best solution by Yahoo! Answers
- How can I change a member's name?Best solution by Yahoo! Answers
- What websites have photos that I can use for a local advertising campaign?Best solution by Yahoo! Answers
- How can I make a second email address on yahoo.com?Best solution by Yahoo! Answers
- How can I get a local business to sell my product?Best solution by smallbusiness.chron.com
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.