Host file is not working
Solved
math 2000
Posted messages
2589
Registration date
Status
Member
Last intervention
-
kaneagle Posted messages 86298 Registration date Status Moderator Last intervention -
kaneagle Posted messages 86298 Registration date Status Moderator Last intervention -
Hello,
I'm trying to get the hosts file to work, but it's not blocking the pages I want
here's an example with Facebook
then when I go to Facebook it is not blocked
I do use a tab between the IP and the URL
the notepad is running in administrator mode
I have unchecked read-only in properties
could someone please pass me a hosts file so I can see if it's the syntax of my file that is the source of the problem or if it's something else
thank you
Configuration: Windows 7, lots of browsers, mainly Chrome
I'm trying to get the hosts file to work, but it's not blocking the pages I want
here's an example with Facebook
Copyright (c) 1993-1999 Microsoft Corp. # # This is an example of the HOSTS file used by Microsoft TCP/IP # for Windows. # # This file contains the mappings of IP addresses to host names. # Each entry must be on a clean line. The IP address must be placed # in the first column, followed by the corresponding host name. The address # IP and the host name must be separated by at least one space. # # Additionally, comments (such as this one) can be inserted on # clean lines or after the computer name. They are indicated by the # symbol '#'. # # For example : # # 102.54.94.97 rhino.acme.com # source server # 38.25.63.10 x.acme.com # client host x 127.0.0.1 localhost 0.0.0.0 facebook.com
then when I go to Facebook it is not blocked
I do use a tab between the IP and the URL
the notepad is running in administrator mode
I have unchecked read-only in properties
could someone please pass me a hosts file so I can see if it's the syntax of my file that is the source of the problem or if it's something else
thank you
Configuration: Windows 7, lots of browsers, mainly Chrome
4 answers
-
Good evening,
Add the addresses as examples (Facebook) after 127.0.0.1 localhost:
127.0.0.1 www.facebook.com
127.0.0.1 facebook.com
127.0.0.1 www.facebook.fr
127.0.0.1 facebook.fr
Human beings are at their best when things are at their worst.-
-
Hi
A concern (?), as my friend JCB would say = "I'm indeed using a TAB between the IP and the URL." !
=> PLEASE, ONLY SPACES; REMOVE THE TABS YOU HAVE USED!
You can add this (it will please ccm); to be opened in admin mode:
hosts-add-google-publicity xp-vista-7 :
http://www.ptorris.com/download.php?file=reg/hosts-add-google-publicity.xp-vista-7.cmd
Add certain Google advertising addresses to the hosts file (stop ADS)
Then you reopen the hosts file you believe to be the right one ...
If there is nothing, it’s not the right file ...
Note:
Windows 7 x64 = C:\Windows\System32\drivers\etc\hosts ("hosts") !
I have nothing in "C:\Windows\SysWOW64\drivers"; no "etc" folder!
Page source of the above link:
Pierre Torris Home Page :
http://www.ptorris.com/reg.php -
-
-
Restore the hosts file to its original state -->> hosts <<--
Then go to Start, All Programs, Accessories, right-click on Notepad, choose Run as administrator and confirm, click on File, Open, browse to:
For 32 bits --> C\windows\system32\driver\etc
For 64 bits --> C\windows\SysWOW64\driver\etc
Select the hosts file, add the addresses as an example (Facebook) after 127.0.0.1 localhost:
127.0.0.1 www.facebook.com
127.0.0.1 facebook.com
127.0.0.1 www.facebook.fr
127.0.0.1 facebook.fr
127.0.0.1 www.facebook.ca
127.0.0.1 facebook.ca
Then click on Save to save.
Human beings are at their best when things are at their worst.-
Hello,
the executable file tells me that the file has been successfully restored, but when I open it afterwards, I see that this is not the case (I made sure to close the programs that were opening the file such as Notepad and ran the executable as administrator)
is the encoding type important, should I leave it as "ANSI"?
thank you -
Thank you, we're making progress. I copied the hosts file from another computer, it blocks Facebook.com but not https://fr-fr.facebook.com/.
-
-
Add this address:
127.0.0.1 www.fr.facebook.com
127.0.0.1 fr.facebook.com
127.0.0.1 www.fr-fr.facebook.com
127.0.0.1 fr-fr.facebook.com
For the encoding type, leave it as is, which is --> ANSI
The human being is at its best when things are at their worst. -
Content for you,
Have a nice day.
--
Human beings are at their best when things are at their worst.