Obtain enough 1-by-6-inch boards to fit the width of the door frame, ripping one of the boards if necessary to create the correct width. Position the boards on the working surface with their largest sides facing up and their long, thin sides touching. Apply a bead of wood glue along one of the sides where each pair of boards connects. Suspend the boards somewhere so the glue won't stick to the surface and clamp the boards together.
Allow the wood glue to dry overnight. Hold the glued boards up to the hinges still attached to the doorway and mark the location of the hinge screw holes on the door. Reposition the boards back on the working surface. Set three boards that are 1/2-by-3-inches and 1 inch less than the door width down on top of the door boards and perpendicular to them. Arrange the three boards so they're evenly spaced but don't interfere with the hinge hole positions.
Drill two holes through each of the three boards into each of the door boards. Set a 1-inch wood screw into each hole and fasten tightly with the drill and screwdriver bit.
Use the drill to make holes at each hinge screw attachment position. Hold the door up to the hinges and attach the door to the hinges with 1-inch wood screws. Check the fit of the door in the frame and adjust by sanding down the edges, if necessary.
Remove the doorknob from the previous door and examine the holes made in the door to accommodate it. Copy these holes on the current door with the drill, keeping the holes in the same position they were on the other door so they can interact with the door frame. Insert the doorknob into the door and fasten it securely with the integral mechanisms. Test the door and make adjustments until it latches properly.