Dryer starts and then stops after about 20 minutes ?
"I think it’s an electric dryer.". When you are not even sure what equipment you are working on, it is time to call a technician.
SSP Bowl Dude
Might be a thermal switch kicking in. Often caused by long buildup in the vent or forgetting to clean the lint filter.
call a repairman
Yes it could be overheating. First make sure the vents are clear, you may want to unplug the cord then take the back off to make sure everything is clear inside the dryer. If it still overheats you either have a sensor tripping low, or a slightly shorted element running to hot. There are videos on how to check some of the sensors and check the current, but the parts sometimes behave erratically, I find it best to just replace the element and all sensors and fuses, if they all have been subject to too much heat they might all have short life remaining, and most kits cost less than $35. https://amzn.to/2G9FdaS
Clean the filters.
I have to agree with the anonymous answer, if you don't even know it it is a gas or electric dryer, it is time to get help from someone who can actually SEE the dryer.
Could be a failed timer, or a failed temperature switch.
Be careful, the hairdryer is overheating and if this continues while you keep trying to start it, a fire can erupt! Has happened me before! Stop using it completely and treat yourself to a new one!