For Facebook Chat I have success in this.
In Pidgin click Accounts>Manage accounts click the Add button.
On the dialog box that appears, choose Facebook(XMPP) option, add your username and password. Click Add to close the dialog box.
Now go back to Pidgin and Click Account>Enable Account>your facebook account.
It fails to enable but after a few tries it is now working for me.
EDIT: This tutorial solves the login problem. Be sure to check it out http://nithinaneeshsct06bt.blogspot.in/ ... buntu.html
"I learned a lot from repeatedly breaking my system and then reinstalling. Oh, and a lot of GOOGLE searches too!"