How to disable xampp from accessing the internet, but enable localhost access by browser

I'm using xampp and had a local installation of a site script in my PC. I want to use Mozilla Firefox browser to see the front-end of the site I'm trying to code, but also want the xampp to not communicate online. Are there any ways to do it without unplugging my ethernet cable?

Upvotes: 0

Views: 3198

Answers (2)

JorgeM
JorgeM

Reputation: 727

For block access to your Xampp web server just click con config>Apache (httpd.conf)

Xammp Options

And edit changing the line Listen to:

 Listen 127.0.0.1:80

You can add a rule to your firewall too, but if Apache, don't serve to anyone else 127.0.0.1, there is no chance for reach your xampp server.

For allow others access to your web server :

 Listen 0.0.0.0:80

Upvotes: 1

James
James

Reputation: 16339

Referencing a similar post on SuperUser, you could use your firewall to block access.

The poster in that question used a third-party program called Comodo, however it would be easy to convert this over to whatever firewall you have. You just want to block {your path to}\xampp\apache\bin\httpd.exe from connecting to the internet.

If you aren't sure how to do this then a quick Google search will show you how.

Upvotes: 4

Related Questions