You can paint a door on its hinges if you place a dropcloth beneath it, or you can remove the door from its hinges.
To take off the door, simply slip out the hinge pins. Lean the door against a wall with two small blocks under the bottom edge and a third block between the top edge and the wall. You can also lay the door across a pair of sawhorses; if you paint in this manner, do not apply too much paint or it may puddle.
Whether you paint a door on or off its hinges, the sequence is the same—from top to bottom.
For flush doors, paint with a roller with a lint-free cover and roll in the direction of the grain.
For doors with inset panels, paint in the following order: recesses, panels, horizontal rails, vertical stiles.
Match the color of the latch edge to the room the door opens into and the color of the hinge edge to the room the door opens away from.
When painting the door casing, begin with the head casing and then work down the side casings. If the door opens away from the room, paint the jamb and the two surfaces of the door stop visible from the room. If the door opens into the room, paint the jamb and the door side of the door stop.
Do not rehang or close the door until all the paint is completely dry.