Sounds to me like this dog is marking territory HE believes he's the master of. I would strongly suggest obedience classes. Take him and learn to be the "alpha" through them. If you've been to obedience school before, go again for a refresher course. He needs to know that you're higher in the pack than he is and that it is NOT alright to be marking the territory that is YOURS.
An inexpensive alternative is to start teaching him tricks. This starts to put you in a higher position, as you will control the training times and treats (which I recommend to start with). Do keep an eye on him and when he starts to sidle up to something like he's going to lift his leg, growl at him and take him out. That helps him start to realize that you are not going to accept this behavior any more.
Let us know how it goes.
Christi
Bookmarks