So, once there, we're all thinking about how to recover to get back to running. What do you do, and where do you go?
The best 1st step is to see a sports injury specialist
I see a sports chiropractor myself. First of all, where the pain is isn't necessarily where the ultimate problem is. One example is ITB syndrome. While felt just above and at the top of the knee, it comes from the hips and glutes pulling upward.
Once diagnosed and being treated, quiz your expert for exercises and stretches which help towards recovery. Injury usually shows up your body's weakest link, so continuing with such exercises post-recovery will also help in stopping the same injury return.
Listen carefully for the recovery timeline. 2 weeks for a purely muscular issue is what I myself am commonly given. I've been going to the same chiropractor for nearly 10 years - since my overweight, pre-runner days in fact, which has the added benefit of him knowing my quirks particularly well.
The first instruction I'm given is not to run
Humbug. Non-impact cross training will keep general cardio fitness from dropping too much, though it could suffer just a little. The stationary bike is a common go-to machine. You can even replicate speed work on them, to a certain extent.
Tip (& joke): if you've been on the bike for more than 30 minutes, cover your mouth when getting off to muffle the squaking yelp you will probably let out from sitting on the diamond-hard seats they tend to be fitted with.
I've used the elliptical for cross training, but suitability can depend on the injury in question. If it doesn't feel right, switch to something like the bike. Swimming of course will be gentle on the joints.
The 1st run back
You might have been itching to run again, I always am. However while away, many of us over-analyze what state we're in. If you're pain free and are within the timeframe you were told to start again, it's time to lace up. A 30 minute trial run if you're used to going an hour+. Take corners nice and gently, slow down a little for them.
Ignore doubts and slight any "tightness" or niggles. Even when uninjured, there's often a random ache during warm-up. A left hip here, a right shin there. The point is to wait until after warm-up (give yourself 10-15 minutes) to truly assess what's going on unless experiencing actual pain.
Go at an easy pace, but not slow enough to make it a jumpy walk which can be worse.
How do you feel at the end of the run, a couple of hours later, and the next day? If all feels good the next day, then recovery has gone well. Aches and tightness a few hours after are ok, within reason. Each runner being a little different will learn these nuances over time, and can gauge how quickly to rejoin a prior training plan.
Planning for prevention
Long term, body and joints strengthen and become more resistant. An enthusiastic beginner should keep in mind that the goal should be to have a high annual average mileage rather than monthly. Over the years this will reap benefits especially when it comes to marathons. Increase mileage by spreading it out more - run on more days rather than making individual runs longer. Weight training has its place, especially free weights which enhance core strength, balancing and stability.
Each injury, as with each race is a chance to improve. Research, analysis and advice from what went wrong - or right - should lead to an improved and more suitable training plan which in turn makes a runner both healthier and more potent on race day.