Hi All -
Just discovered I had this same problem. It turned out the connector for the camera had come unlugged, perhaps after a phone drop.
Follow these directions:
Specifically, I opened the phone, carefully pulled the battery out of the way (without unplugging it) and skipped ahead in these directions to the removal of the wifi-antenna in step 13.
When I pulled up the antenna, which is just a little black metal plate with several screws in it, the offending connector came up with it (the blue square in step 17) so I just pushed it back in.
I reattached the antenna, restarted the phone, and it worked.
Dont worry about all the other steps - just move the battery out of the way and ONLY USE STEP 13!!! Step 17 is only useful to show you which connector needs to be reseated.
Be careful with the screws!!!
Total time was about 10 mins, though I am relatively handy.
I don't know how "pushing" the camera into place is working for the previous posters, but do yourself a favor and open the phone to do it right.
That has worked for me before on occasion with my ringer switch. was experiencing issues with front camers freezing when i switched to it just like you. after reading all these responses i took off my case to apply the pressuere but the front camera worked as soon as i took the case off, so try that first. my issue may have been pressure in the wrong spot due to my case, because i have an extra screen protector and money stuffed inside by case so maybe thats youre problem. good luck!