In this link the DC motor speed and direction was controlled....its nice...but i have an doubt ....... How do I control a DC motor with an encoder using Arduino?...
http://www.ingenstech.com/19-dc-motor-control-arduino-beginners/
http://www.ingenstech.com/19-dc-motor-control-arduino-beginners/