As others have said, skip the weights as your muscles will feel like dump and you won't have a good workout. Plus you'll get others at the gym sick.
Cardio is ok though, as long as you're not going balls to the wall. General rule of thumb is that as long as the problem is above your neck (i.e. head cold and not affecting your lungs), you're ok to exercise. I've gone running with a cold many times, and if you don't go too hard, it's actually beneficial in clearing up a stuffy nose, etc.
If you have a fever or chest congestion, skip all exercising.