i had this problem 3 times, first time i went to get my phone changed, thinking that it was a hardware problem....but the same thing happened to my new phone, so i guessed it wasn't hardware related. I solved the problem by doing the network reset on the phone, and also updated my router's firmwire. yesterday i had the same problem AGAIN (after a few weeks), there was no firmwire update for my router, the network reset didn't work, so i re-installed my router's firmwire, and it works again....
i hope this works for you guys too
(FYI, i use a Linksys router)