Chat/Game help

hey yall,
I wanna start learning how to program a virtual chat game in flash mx
and i know web porgramming/animations ect but i dont know were to start
my first goal is to complete a chat room simple then add stuff
then somthing like this http://www.gotoandplay.it/_games/_theoChat//avatar.swf
and once i can do that i think its all down hill from there but
were should i start can someone please help me out with
some…ebooks/sites/articles ect

how would i make a sevrer for it what programming language do ilearn
some tutorials on beginner chats for flash mx ect
anything is helpful and i thank you very much for it!:pleased: