Hi,
It sounds like the back is involved. The symptoms are commonly known as Sciatca although this will need to be checked properly.
There are many reasons why you might have pain in the leg. The fact that moving helps your pain may mean you have a sustained position dysfunction and need to learn to control your posture differently to how you currently hold yourself.
Just because your hamstrings are tight, it doesn't mean they are - they might just be overactive in trying to protect you.
If you haven't seen a physio yet, do so. Find a good one. If you have seen a few, then let us know what they have done to see if there are any gaps we can help with... Cheers