| | Hi im using xampp to view my php files ( http://localhost/test.php). Now i want others to access my xampp folder. Means to view the php file from another machine by typing this (http://[ip]/test.php). how can i do that? tnx |
| Nov 23, 2009 |
You might be able to do this without much trouble, but if that method does not work, you will probably have a lot problems getting it to work.
I am guessing that you have a dynamic IP address and a router? If I am right, access your router configuration - it is probably located at 192.168.1.1. What you will need to do is forward some random port to your computer, in order for other people to be able to access it. It is best to forward some rarely used port, such as 8342
also, make sure you have your firewall configured to allow access to your computer on port 80.
The easiest way to find your IP address is to open Command Prompt (i.e. Start > Run > cmd > Enter) and type in 'ipconfig' (without quotes) and hit enter. This will display your current IP address. You should then be able to enter that into any other computer on your network, if that wont load your page, try the port forwarding for your router/modem as pyost suggested. If that fails to help, check you have basic communication by pinging the server. If this doesn't work - you have a basic communication problem which you have to solve first! Good Luck!
Actually, if your computer is connected to the Internet behind router.
The only way to connect to your computer from outside world was port-forwarding. After configured it. You may download a copy of utorrent. It is used only for test case as it provides a test port function it will tell you the connection work or not.
Also something else make other people unable to connect.
usually, in your Apache settings, when you automatically install XAMPP, in the httpd.conf file, the Listen instruction is a line like : Listen 127.0.0.1:80 That means that Apache will listen only on your localhost (The one attached to your keyboard). This means that even other computers on your network will not be able to reach php program. I would replace the Listen line by two other lines. Let's suppose that your computer local network name is "mylovedcomputer", I would replace the Listen 127... line by the two following ones : CODE Listen 127.0.0.1:8080 Listen mylovedcomputer:80 This means that your php program will be reached internally at the address localhost:8080 (instead of the default 80 port) and your Apache will listen the other computers from your home network at the adress mylovedcomputer:80 View Php In Another Server In the address bar of your internet browser, type in 192.168.1.1. It should ask for a password, if you don't know it, look up the default password for your router. Mine is no username and the password as admin. There should be a link that looks like Applications & Gaming or like make a new server connection or even Port Forwarding. Once you are there, enable a port, open ports 20 and 50000 (or whatever your server requires), and have those ports forward to a number that you will find out in this next step. start -> Run... -> "cmd" -> OK -> "ipconfig" One ip address that shows up should be 192.168.1.XXX. That XXX number is what you need for the IP address that the port will forward to in the previous step. Now for other people to view your site, they need to type in your IP address in their address bar. You can go to ipchicken.Com to get your IP address. Note: some IP addresses change (including the XXX number and the ipchicken number). -reply by Ben Maerkle
Similar Topics
Keywords : view, php, server
Authorization server variables not staying across pages (14) This is quite a bit of problem I am facing, and I cannot point exactly where I am going wrong. I (9) Hi, i'm developing a web application which obviously requires a log in/log out script that i Help Needed Please (5) I'm trying to create a script that will generate an image and send it back to the browser while Server preformance, response time (4) Hello there. Most of my programming experiance has been with compiled languages. However, I am now (5) Hi I'm relativly new to php... I'm interested in writing server-friendly php scripts and i Grab it right now ... (5) Hi, Those who don't want to go into all the hassle of configuring Apache with PHP - fsockopen() on a Irc Server (7) I have create a script that open a connection on a irc server like a BnC; when i test it on my local PHP4,PHP5,ASP.Net (13) Hello, I'm hosting my own site web on my computer. I'm using IIS6 with ASP.NET and PHP4 Looking for view, php, server
|
![]() View Php In Another Server |
Affordable Web Hosting, Low cost Web Hosting - ComputingHost.com