Obay
Obay

Reputation: 3205

How do I access my own website hosted in my machine?

Forgive me if this is a stupid question.

I am running XAMPP (lite) for developing my website. I can access it through http://localhost/mysite

I wanted to view it on another computer (just for testing purposes), so I went to whatismyip.com, got my ip address, and tried to access the site from another computer using http://xxx.xxx.xxx.xxx/mysite

Am I doing it right?

Anyway, I get a "Enter your username and password" prompt. I've tried the following usernames and their passwords: 1) My computer name 2) My windows login username 3) My database username

None of them worked. I already have my firewall OFF.

Any ideas?

Upvotes: 0

Views: 1293

Answers (2)

Cooper6581
Cooper6581

Reputation: 241

Apache might only be binding to localhost. Open up a command prompt and do a netstat to see what address is being bound to on port 80. While you are at it, do an ipconfig /all to see what the IP address is of your machine. If you have a DSL/cable router, you probably have a private IP address which by default isn't accessable from the internet unless you setup port forwarding. If you want to access your computer from inside your home network, try accessing it using the IP you got above. If you want to access your computer from the outside, read the documentation for your cable / dsl modem / router to see how to setup port forwarding.

Upvotes: 0

styts
styts

Reputation: 1023

If you are behind a router, then the credentials you are prompted for are those of the router.

You will have to setup your router to forward HTTP traffic (port 80) from outside to your PC if you want others to view the site.

Upvotes: 4

Related Questions