I have installed a virtual machin with Windows XP using Virtualbox and i want to acces the localhost from it (i am using Wamp Server). Is it possible? I am using Windows 7 on mi computer.
Open the virtual machine settings window from within your installation of VMware Workstation, VMware Server, or VMware Player by clicking VM > Settings. In the hardware tab, highlight the network adapter and ensure that the bridged network connection checkbox is selected.
You need to find what your local network's IP of that computer is. Then other people can access to your site by that IP. You can find your local network's IP by go to Command Prompt or press Windows + R then type in ipconfig . It will give out some information and your local IP should look like 192.168.
To access the server from itself, use http://localhost/ or http://127.0.0.1/ . To access the server from a separate computer on the same network, use http://192.168.X.X where X.X is your server's local IP address. You can find the sever's local IP address (assuming it's Linux) by running hostname -I . 127.0.
This solution works on Mac OS X: open IE and simply enter the URL http://10.0.2.2:8888
(8888 is the Apache port, in MAMP is 8888).
Also, for a better solution: open your hosts
file in C:\WINDOWS\system32\drivers\etc
and add this line:
10.0.2.2 localhost
For a more comprehensive explanation check this link.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With