There are some causes for connection to the router but no internet such as expired antivirus and malware but here we have little to work with. Until you know more, reboot, test then forget this WiFi connection (varies with OS) then connect again.
My computer suddenly lost Internet connection yesterday. It is still connected to the network (through ethernet, not wireless), but it can't access the internet. I have several roommates who are experiencing no issues with the internet, both through the wireless connection and ethernet. My computer is the only one having the issue. Can anyone help me fix this?

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic