I just found this thread last night after experiencing the same problem with my brand new iphone. It was only on for about an hour when the wifi stopped working. It was greyed out on the menu and said "no wifi." I tried resetting the phone numerous times, turning it on/off etc. and nothing worked. I made an appointment for the Genius Bar and went in this morning to have them look at it. They wiped it clean and re-installed the os and it still didn't work. He said that it must be a problem with the hardware and exchanged it for a brand new one

. This was the first phone they had seen this issue with and it doesn't seem to be a widespread problem. I'm very thankful Apple took such good care of me. If anyone else has this problem in the future I would recommend taking it in and getting it replaced if resetting the phone doesn't work for you.