the short answer
To warm up for a workout, do a general warm-up of 5 to 10 minutes of easy cardio to raise body temperature, follow it with dynamic stretches that move the joints through the session's ranges, then do a few specific ramp-up sets on the first lift that climb toward your working weight. Save static stretching for after the session.
This article is general information for coaches and clients, not medical advice. Severe or persistent soreness, swelling, or dark urine after training is not normal - refer clients to a doctor rather than coaching through it.