Any more information on your filtration - are you using adequate mechanical and chemical? Could there be a dead fish or large chunk of food hidden somewhere in the tank or filter? The story seems quite strange as you tell it. At the very least, check out your filter really well, and add some new, quality activated charcoal.
When the water was "messed up", did you use any additives (chemicals)? If so, that might have shot your biofilter.
If you have ammonia and nitrite in an established tank, you have a problem. Along with finding the problem, you need to do daily 50% changes until ammonia and nitrite go away.