I have gone through these workout slumps too, and I have found when I begin to get depressed and am having trouble getting a good workout in I do these steps:
1) Watch Pumping Iron. I never really knew what bodybuilding was, but the first time I watched pumping iron on dvd I knew that bodybuilding was what I wanted to do with my life. This DVD gets me pumped up every time and makes me want to get in the Gym. Every time im in the squat rack and Im just about to give up I think of Arnold saying "Two more Eddie, I wanna see two more, no matta what." Others say they like a video like Colman's where they can see a guy move a lot of weight. I suggest you find a video to use as motivation.
2) Get a Supplement and soak up its placebo effects (try not to use prohormones/steroids). Get a supplement that makes ridiculous claims, such as some type of creatine or NO2 and milk it for its placebo effects. If im having trouble with my workout program, I'll pick up a supplement and read all its label and magazine claims. I will think to myself, "This stuff is making me bigger and stronger; because I am on this, I can do two extra reps." By the time the first bottle of the stuff runs out I'm usually back into workout mode and dont need to use it anymore. During that transition time I usually tell myself how false the manufacture's claims were and how I can do just as well without it and this usually ends up acting as a reverse placebo effect. I say try not to use ph/steroids because I have a friend who imo has become dependent on them for lifting. He will go without lifting for months and on his binge drinking diet and then come back to the gym and start up a prohormone and lift. He says he likes it because it helps him to see results fast and keeps him in the gym, but then it seems that once he goes off of the prohormone he goes back to his binge drinking and not lifting.
3) As others have said, temporarily change your diet and training. I usually find that I have been overtraining so I try to move to a 3 day a week split doing basic compound movements, training like a powerlifter instead of a bodybuilder. However, sometimes I will change my routine up by doing a ton of cardio, to loose extra pounds. I also do a lot of "healthy" cheat meals. If I'm with friends and we go to get pizza, I get bbq wings. If we go to get burgers, I prefer to get two burgers and water instead of the burger, fries and a coke/beer like most people eat. Its not the most healthy diet, and im sure some on here will rip me a new one for suggesting this, but I have always found that if you keep your diet in moderation all the time, you generally stay lean.
4) Take a vacation if you can and dont train at all. I have always found that when I go on vacation and dont do anything while I'm there, I feel like absolute **** by the time I get back and the first thing I always have to do is a full body workout in the gym. And if i wasn't very into my workouts before the vacation, I find Im always giving 110% after it.