Attempting to view your website using the temporary URL 'hostname/~user will not work well if at all with php scripts.
In order to see a site on our server while the rest of the world is seeing it on another server the
hosts file on your computer needs edited.
The hosts file, a plain text file located on your computer, is an override of sorts to checking dns externally. It is also called hosts or host with no extension in virtually all operating systems, although the location of the file will vary by OS and even version of OS. More on hosts files
here.
In Windows XP it is located inside c:/system32/drivers/etc/ but a search for the filename will give its location.
Open in a text editor and add your server's IP, which is in the welcome email, and your domain name. For example:
8.9.24.24 example.com
8.9.24.24 www.example.com
8.9.24.24 subdomain.example.com
Editting alternative:
Don't want to go rooting around for the file? This will edit the file.
1.) Open
start |
run & type
cmd in the run box.
A black window should open.
2.) First back up the file for safety by copy and pasting this command including the word "copy".
This backs up your hosts file.
copy %windir%\system32\drivers\etc\hosts hosts.bak
3.) Then
replace the example IP addess with the IP and domain name of your server and paste these commands:
echo 67.76.156.111 example.com >>%windir%\system32\drivers\etc\hosts
echo 67.76.156.111 www.example.com >>%windir%\system32\drivers\etc\hosts
--
To remove it manually edit the hosts file, or open a command prompt again using step 1.
Then paste this:
copy hosts.bak %windir%\system32\drivers\etc\hosts
Answer yes at the yes/no prompt.
This will make it so your computer goes to the new server, but all other computers on the Internet see it at the old server.
It is a good idea to remove that spec once the site is resolving correctly.
-
Note - for Windows Vista users, the file will need edited using the command prompt running as the administrator.