Ok, I agree with everyone who says that it's better to learn the ideas rather than just memorizing opening lines like a machine. HOWEVER - I feel that once a player gets to a certain level it becomes very important. Im just now starting to peak over 1500 and have been advised by the masters and IMs at club to start memorizing lines in ADDITION to knowing the ideas of the opening. Memorizing lines is inferior to understanding the ideas, but having both is best!
With that said: I find the lines I want to play in a particular opening and enter them into a program called 'Chess Opening Trainer.' This program is really easy to use, lets me save my openings in various files for ease of use, and tests my knowledge by randomly giving me positions from what I've entered into it to see if I know the follow up.
I love it.
Remember though, no more than 20-25% of your time on openings! Tactics Tactics Tactics, endgames, strategy and planning!