the leg thing is most likely from you pushing too hard trying to go. Its ***** with some nerve that causes muscles to feel weak and achy.
Lots of water. easily digestible foods, more fiber. no gluten, dairy, fast food, highly processed foods.
try eating a clean diet. chicken, turkey, fish. steamed veggies. fruit (no skin).
Start taking a strong probiotic. the ones you find in the refrigerator at a health food store. id probably go for something like 50 billion cultures. Go for mega foods brand or Raw brand
constipation is most normally the result of your diet. i would look up diets for constipation and eat food that more digest-able. however I'm not sure about your leg, Perhaps it is a blood clot? I would see a doctor about that if it is persistent when you're not trying to go to the bathroom. you could also take stool softeners for awhile to help. if it feels like it's getting blocked at the exit you might have some sort of muscle spasm that only a doctor can diagnose. It sometimes requires botox or surgery (don't be scared). I just want to also warn you to not keep pushing so hard when you're going to the bathroom. Anal fissures are real and definitely something you want to avoid at all costs because of the pain. they are basically little cuts at your anus that are difficult to get rid of and heal because your anus has to keep stretching to get your feces out. Anal fissures are most often caused by constipation and straining and is fairly common with constipation. I would see a doctor if this gets worse! your health if important!