Basic Grammar Practice
English Page is a good collection of fundamental grammar rules with explanations, examples and exercises. A good first reference point.
Advanced Grammar Practice
The Purdue OWL (Online Writing Laboratory) is a huge reference to improve your writing. They have a large section of grammar and punctuation rules for native speakers for your most difficult grammar questions.
About.com has a lot of resources although it may be difficult to find what you are looking for if you don’t know the correct terminology. Use your textbook or another grammar reference to identify what you are looking for and then search the page here.
Grammar Exercise Books
Raymond Murphy’s Grammar in Use Intermediate is one of the most comprehensive books around of grammar rules and exercises. Every student should have this. There is also Advanced Grammar in Use, and while it is very complete I think it is appropriate for an extremely high level (Cambridge Proficiency Exam). A good exercise book in between these two is Cambridge Grammar for CAE and Proficiency.
Grammar References
Sometimes an exercise book just isn’t enough and you really want to know the details. This is when you need a grammar reference. Practical English Usage and Cambridge Grammar of English are two of the best.