Viewing 2 replies - 1 through 2 (of 2 total)
  • How is this network setup? Are you talking about multiple private networks, that, for example, share a building? Or are you trying to connect to your local WP over a public network (the way you connect to this site, for example)?

    If the latter (and if I understand what you are doing), you can’t do that the way you are trying to do it. ‘localhost’ always refers to the computer executing the program, hence the name. You can use ‘localhost’ in wp-config because the server execute the php and mysql, then sends it to the browser. But you can’t use a http://localhost address except from the computer that is running the server. Make sense? Those ‘192.168.*.*’ pretty much always refer to the local network. So, essentially you are sending the request to various IP addresses that may or may not have servers on them and certainly, in all but one case, don’t have your files on them. For example, when I click the link to http://localhost/~patrick/wordpress/ that request goes to my local server which of course doesn’t have your files of directories on it.

    If you are talking about private networks only and your server has a static IP you can set to DB_HOST to that static IP and it might solve your problem. If you are routing through public networks you’ll probably have to connect via a Virtual Private Network (VPN).

    Thread Starter misterpatrick67

    (@misterpatrick67)

    Thanks for the tips. I just figured out the problem by searching for 192.168 using myPhpAdmin. Looks like when I set the site up I used the IP not localhost for the site location. Changing this in the config file did not change the database. So changing that in the DB fixed it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Problem with localhost’ is closed to new replies.