before you get all panicky......
how many times has this happened.....??
if once .... well don't do anything ....
What was the website?
some of the (shall we say) less legitimate sites - and unfortunately more elaborate legitimate sites ron code which can occasionally trigger a restart.
if you are re-starting regularly .....
boot from a floppy ... or cd... or usb
let the machine run and see if it restarts .... if not ... it's probably software.
check virus, adware, hijackers ....
I assume you already do .... regularly(?)
and go from there...
as a last resort ..... you may have to rebuild your machine.