What you need to do is edit your host file, so that your browser checks this first before the domain DNS.
- Open a terminal window. (Applications/Utilities/Terminal)
- Type this line in:
sudo nano /private/etc/hosts - You will be requested to type your password in.
- The
terminal window will then show any current host settings. Now add the
line you want. Use arrows keys to position flashing cursor where you
want.
EG: 127.0.0.1 mydomain.com.au - Once done, hit Control+O to save. Then press Enter.
- Now exit Terminal - Control+X.
You can also download a "Hosts" application that will install and be available from System Preferences. However this will not work for all OSX versions. Terminal is a better way to go.
For more advanced users, you can use "sudo vim".
To flsuh DNS in OSX 10.5 + use "dscacheutil -flushcache" - for OSX 10.4 and below, use "lookupd -flushcache".
NOTE: Had a few questions on this, if you add domain without "www" - you need to check in browser without the www as well.