Get wired and see if it happens.
There are wifi issues that are discussed such as WEP or less security but the details are so light in the opening post I can't guess if that's part of the issue.
Also, some firewalls, antivirus suites tend to do this as they near expiration to prod the user to renew their license.
I have two Windows XP systems at thome, both Dell laptops, one is my personal machine and one is a work laptop.
My work laptop is connected to my wireless network and via VPN to my work network almost 24x7. I never have any issues connecting or staying connected to the VPN or accessing the internet.
With my personal laptop, every time I use it and am online accessing the internet, at right around the 5 hour mark, the internet access stops working. My wireless network shows that it is still active and connected, but I cannot get to any web sites.
If I put the machine in hibernation prior to the 5 hour mark, it will then come back up when I wake it, and will then connect to the internet with the 5 hour timer seemed to have reset.
Any ides on what might be causing this?