I turned my Iphone off and it will come on for about 30 seconds then it will shut off. I had it charging for sometime and its still doing the samething
You should put the phone into recovery mode and restore it.
1. Plug phone into USB cable, open itunes.
2. Hold home and sleep/awake button down.
3. When you see apple logo release sleep/awake button.
4. Continue holding home button.
5. When you see connect to iTunes message on phone release sleep/awake button.
6. Restore phone via iTunes.
If this method doesn't work try holding down the home button while plugging in the cable.