Donna, I assume we are speaking of a fiberglass or similar type shower pan that has at least one finished curb & face (where a door kit or curtain would be).
The nailing flanges that extend upward from the other edges go tight to the wall framing, and the wallboard goes over top of them. (The flange winds up "sandwiched" between the framing and the wallboard)
The flange should be predrilled where it rests against studding, and carefully screwed or nailed to the wall studs at these points. It doesn't need to be attached at studs directly in corners (the rounded edge will break if you try this), and be sure not to force the floor pan out of plane. If it doesn't fit snugly up against a stud, or one entire wall, shim the pan at the studs, then attach, and shim the entire face of that wall or stud as needed to get a flat surface that is in plane.
Keep the wallboard up from the ledge (bottom of flange) at least 1/4", but no more than 1/2".