Whirlpool dryer

I have had this dryer for over three years. My husband was doing a load today and he said it never turned off. I started the dryer, turned the timer to off, and it kept going. Only way I got it to turn off was opening the door. What could be causing this?

Jennifer