I just got this error and I found out that it could be caused by a different issue than firewall rules.
For some unknown reasons, my HOSTS file was damaged and it lost the mapping of "localhost" to the IP address 127.0.0.1. So, since it was not possible to resolve the name localhost in its corresponding IP address, PhpED correctly reported the error outlined in this thread.
So, if you get this error, apart firewall rules make sure to check in your system the HOSTS file settings also. Inside that configuration file you must have an entry like this:
127.0.0.1 localhost
To read more information about the HOSTS file and where it is located in your system, you may check Wikipedia at the following URL
http://en.wikipedia.org/wiki/Hosts_file
Hope this could help other people to fix the issue quickly