You learn a new song on your guitar and after practising it a lot you SWEAR you have it down right then after awhile you can't even play a riff or two (maybe even the whole song) right?

Like....I learned Metallica's The Four Horsemen and I thought I had it down right...then after a week or two I kept screwing up the main riff which I thought I had down...
strange that, i remeber most of the stuff i learn, well as long as its something i want to learn

i've spent the last like 3 days trying to nail this 3second shredding thing on stratovarius's speed of light, hehe, just to say if ure learning some thing shreddy trun off the distortion then u have to play it better so u can hear it, then after a bit turn on distortion, tht improved me so much
maybe you're just having a bad day. And your frustration is making you screw up more.
try learning it, then playing it w/ the actual cd going so that you're playing over the cd, that way it really cements itself into your brain, thats how i got to be a living breathing metallica library (or at least was for a while, i haven't done that in years now)
Well, it's not just learning songs...I can't play as fast as I used to...and now I screw up songs more often than I normally do
Maybe try taking a break for a day or so, you should feel refreshed and eager to get playing again.

Other than that, just practice slowly, play along with the record, or play something else for a while.
^ has some good ideas, if its your speed thats not as up to par as it used to be you might want to figure out why, are you tensing up? do you have arthitis or carpal tunnel or anything that might be affecting it? (i have both CT and arthritis and can still shred like hell cuz i don't have any tension in my hands) is it that you can start fast but just don't have the stamina you used to? do your hands feel tired all the time? i think speed is like riding a bike, it never goes away, you just gotta figure out whats keeping you from acheiving it.
do regular finger scale excercises, both for left and right picking hand. Should do about every 2 days or so to maintain strength and endurance