Iphone 3g stuck on apple logo and will not reboot

my phone was acting up so i shut it down and went to reboot it. Now its stuck on the apple logo and will not turn on. if i leave it on and let it go for a little bit it will restart like its trying to boot it again. my phone is jailbroken also. any help. tried to hold power and home button for 25 seconds. didnt work. itunes wont recognize it either.
http://www.theiphoneblog.com/2008/10/09/how-to-problems-with-your-iphone-restore/

Try following those directions.

Original thread: https://forums.imore.com/threads/iphone-3g-stuck-on-apple-logo-and-will-not-reboot.181353/