How to block/unblock a domain (for web browsing)?

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
budhax
Posts: 63
Joined: 09 Oct 2006 12:25

How to block/unblock a domain (for web browsing)?

#1 Post by budhax » 02 Sep 2008 18:26

Hello,

A.
Is there a DOS command to block/unblock a specific domain (like www.game.fr)?

I would like the same/similar result as adding/removing this line
127.0.0.1 www.game.fr
in this file
c:\windows\system32\drivers\etc\hosts

Ref: http://forums.winamp.com/showthread.php ... ost2067327


B.
If I use this basic way:

Code: Select all

echo 127.0.0.1  www.game.fr>>"c:\windows\system32\drivers\etc\hosts"

how to target and remove the added line (using DOS commands) to unblock the domain later?

Thanks and regards

carlitos.dll
Posts: 11
Joined: 02 Jul 2008 07:42

#2 Post by carlitos.dll » 05 Sep 2008 11:38

The author has been removed this message.

Post Reply