when ever my friend tim comes over, my 7 month old female pug, grace, pees. its not just being excited and peeing n the kitchen, she goes up to him and pees on his leg when he pats her. every time he comes over, wihthout fail, she finds him and pees on him. is this a sign of effection, like when male dogs hump things? is there any way to train her not to? its a real problem because i hate locking her in the kitchen or putting her out side in the cold every time he comes over. please help
Take her to obedience training, if you haevn't already. Teach her that she is to sit/stay when guests come over. Put her on a leash so that she can't get at him and do it. I'd personally think this was some kind of submissive urination issue, especially if you are a woman and your friend is a man. Some dogs react totally differently to men than they do women. If your friend totally ignores the dog and doesn't pat her or anything (since you say she only does it when she's being patted) this alone might be enough to fix the problem.
if males hump it's a dominance thing, rather than affection. they're trying to dominate what they hump. the pug pee thing could be a submissive thing, she's telling your friend he is dominant. i'd agree, talk to a trainer about it.
Sounds like a submissive behavior. We have a male friend who accidentally scared our Boston. Still to this day, even though she likes him, she cowers and pees when he comes over. I always make them greet eachother outside!