Currently Being ModeratedJan 23, 2013 3:16 PM (in response to jackpot1515)
Sounds l,e a problem with your router. The iPhone switches automatically to cellular when a Wi-Fi signal is not present. But in your case the Wi-Fi signal is there but the router seems to have lost the connection to the Internet.
Try rebooting your router bye wearing off for thirty seconds then turn it back on. Also reset your device. Press and hold the Home and Sleep buttons simultaneously ignoring the red slider should one appear until the Apple logo appears. Let go of the buttons and let the device restart. See if that fixes your problem.