no expert on this, but try rewarding him when hes calm, like when walking past people, if hes good and doesnt whine, say "leave" and when he does say "good leave" and give him a treat. possitively reinforce as much as possible, then when you can see his attention straying or getting excited, tell him to "leave" so he associates the word with - Mom wants me to shut up and keep walking and i get called good jake and get food for it".