I wouldnt suggest doing it when you are both in cars that are moving. The distance between the two cars and relative speeds may not give good results.
If you really want to try it though just follow below but you may need to take a lot of photographs, the cars movement will judder the camera a bit and produce unwanted movements
For a still cameraman. Choose a spot, the cameraman gets out, driver starts a run past, for motion blur choose an aperture priority mode if you have one, or something that will give you a reasonable fraction of a second exposure. If all you have is program modes just try several and avoid sports modes.
Take pictures as the car goes by by actually following it in the viewfinder and pressing the button at the right moment. Being a bit further back from the road will give you a little more time to aim but will make the car smaller on the picture.
If its still not good enough then fake it in photoshop or PSP