I want to set up a proxy server for a school to prevent users to log-in to site like Facebook, Youtube, etc.
I have no idea how to do this, so I´d really appreciate your help.
It may be easier for you all to use a DNS service such as OpenDNS where you can block based on hostnames and/or web categories. This will be a lot easier to setup and maintain if you are not very familiar with IT. Here is the direct link to their web content filtering - https://www.opendns.com/web-filtering
You'll probably want to look into a proxy like Squid which can do what you're describing with relatively little set up.
Squid is well documented and heavily used, so it would be a good solution for anybody in either a development phase or in a production environment.
I would suggest using something like untangle It will give you what you are looking for, and there are a bunch of bolt on features that you can use in addition to web content filtering (which is one of the things you are trying to do).