When shooting, make sure the lighting is similar for best results. It wouldn't surprise me if the photo of her standing up was taken right before or after the main one in the same place.
Then, it is a matter of removing the background from the photo that you want to nest in. It can be done with some automated techniques if the background is a different color from the subject (using the magic select tool) or can be manually painted out by erasing the background from a layer that it is on.
This new subject only layer can be scaled and positioned over the background plate so that the positioning is correct and then some shadows are either painted in or projected in based on the shape of the layer and a light source direction. Some other minor airbrushing changes might be done to help blend the image together better, but that's the general idea.