Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: editing hosts file  (Read 2741 times)

0 Members and 1 Guest are viewing this topic.

jonnyD

    Topic Starter


    Intermediate

    editing hosts file
    « on: September 08, 2007, 09:49:03 PM »
    I tried to block a couple of websites in my hosts file by adding text in the format as follows:

    127.0.0.1 www.whateverwebite.com
    127.0.0.1 www.anotherexample.com

    The websites were not blocked.  My default browser is Mozilla Firefox, although I also have an Internet Explorer icon on my desktop which I also occasionally.  Regardless of which browser I use, doesn't it have to access the hosts file to translate the domain names into IP addresses?  And if that's the case, why are the websites I chose not blocked?


    Fed

    • Moderator


    • Sage
    • Thanked: 35
      • Experience: Experienced
      • OS: Windows XP
      Re: editing hosts file
      « Reply #1 on: September 09, 2007, 12:29:51 AM »
      Is it saved as HOSTS without a file extension?
      This may not be apparent if your windows explorer is set to hide files with known extensions.

      patio

      • Moderator


      • Genius
      • Maud' Dib
      • Thanked: 1769
        • Yes
      • Experience: Beginner
      • OS: Windows 7
      Re: editing hosts file
      « Reply #2 on: September 09, 2007, 09:01:56 AM »
      How To's of the Hosts File

      Grab the beverage of your choice...it's a good read.
      " Anyone who goes to a psychiatrist should have his head examined. "

      jonnyD

        Topic Starter


        Intermediate

        Re: editing hosts file
        « Reply #3 on: September 10, 2007, 07:03:00 AM »
        I've seen this page before and the MVPS page with the unwanted sd-site lists.   Maybe up the road I'll put this page in place in my hosts file, but right now I'm interested in blocking particular websites which are not ad sites.

        Do you know if each browser (Mozilla Firefox & Internet Explorer) relates to the hosts file differently?  I would figure once I get into the hosts file, regardless of which browser I'm in, and put the site addresses I want blocked there, that's all I have to do.
        And yet the sites I entered in the manner I put in the above first entry are not blocked........

        Deerpark



          Egghead
        • Thanked: 1
          Re: editing hosts file
          « Reply #4 on: September 10, 2007, 02:07:38 PM »
          The browser shouldn't matter. All of them rely on Windows for DNS resolving and Windows should be looking in the hosts file before resolving a DNS name.

          Try removing the www part so you only got the host names. I.e. computerhope.com instead of www.computerhope.com

          you can also try clearing the Windows DNS cache:
          Go to start and select Run...
          type ipconfig /flushdns and hit enter.
          Any sufficiently advanced technology is indistinguishable from magic.
          Arthur C. Clarke (1917 - 2008)

          jonnyD

            Topic Starter


            Intermediate

            Re: editing hosts file
            « Reply #5 on: September 10, 2007, 09:11:08 PM »
            OK, did both - the flush and remove the "www".  Nada.  Still see the websites I don't want to see.  Any ideas? ???