Most of us some times try to block a website for child safety from violence and adult content .Some of us try to find softwares to do so.
Today i will be explaining that you do not need a software for the purpose of blocking a website , you can do it just from host file located in windows The host file acts like a filter for all the internet traffic occurring through your computer.
The hosts file is a simple plain text file lying in windows having no extension with no extension, it contains lines of text containing IP address and the text is followed by one or more host names(i.e. website name ).
To know about host files in different operating Systems Click Here.
Open the hosts file in notepad, and if you (or some virus) haven’t made any changes earlier, it would look like-
The host file contains most of the explanation about itself.
If you want to block a website(just say facebook),then just add the following textafter the ip
Appending these two lines in the text, and saving the file would completely block facebook from your computer, none of your browser, application, anything, would not be able to access facebook.
Make sure, to successfully block a website, write both the lines.
Another Example, to block Yahoo!
Don't prefix the # sign as it is use for commmenting.If you used the line will have no meaning ,it will be worth.
Today i will be explaining that you do not need a software for the purpose of blocking a website , you can do it just from host file located in windows The host file acts like a filter for all the internet traffic occurring through your computer.
The hosts file is a simple plain text file lying in windows having no extension with no extension, it contains lines of text containing IP address and the text is followed by one or more host names(i.e. website name ).
The location of hosts file in windows is-
C:\Windows\System32\drivers\etc\hosts
To know about host files in different operating Systems Click Here.
Working on Windows:-
Open the hosts file in notepad, and if you (or some virus) haven’t made any changes earlier, it would look like-
# Copyright (c) 1993-2006 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a ‘#’ symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host
# localhost name resolution is handle within DNS itself.
# 127.0.0.1 localhost
# ::1 localhost
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a ‘#’ symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host
# localhost name resolution is handle within DNS itself.
# 127.0.0.1 localhost
# ::1 localhost
The host file contains most of the explanation about itself.
If you want to block a website(just say facebook),then just add the following textafter the ip
127.0.0.1 www.facebook.com
127.0.0.1 facebook.com
127.0.0.1 facebook.com
Appending these two lines in the text, and saving the file would completely block facebook from your computer, none of your browser, application, anything, would not be able to access facebook.
To unblock a website , simply erase the line you wrote.
Make sure, to successfully block a website, write both the lines.
Another Example, to block Yahoo!
127.0.0.1 www.yahoo.com
127.0.0.1 yahoo.com
Don't prefix the # sign as it is use for commmenting.If you used the line will have no meaning ,it will be worth.
we have just done it.
No comments:
Post a Comment