Topic summary
Out of play

Extracted from the Wikipedia article Ball in and out of play.
Restarts
Once the ball is out of play, the only restart is the restart appropriate for the reason the ball went out of play in the first place; subsequent actions do not change the restart. For example, if the ball goes out of play because of a foul by Team A against Team B, the restart must be a free kick to Team B even if a Team B player strikes an opponent; offending Team B player would, however, be liable for misconduct (i.e. yellow card or red card).