I was trying on blocking some of the websites that I usually use even I need to work hard, e.g facebook.
I am using Ubuntu 9.10 and I tried to change the /etc/hosts file by adding www.facebook.com next to the "127.0.0.1 localhost" statement.
Now, if I type www.facebook.com to my browser, an error message appears and says "oops, the link is broken" but if I try to access to facebook by using the IP address 18.104.22.168 my browser can still access to facebook. If anyone knows a more clever way to block access to a website please reply. Thanks.
Oops, sorry one more question, can I use the iptables command in linux to ban a website? If yes, how?