Dogs don't want humans to approach them too fast, move erratically, hit them, that kind of thing.
These are the basic, mostly understood manners. Then there are the laws, which allow for the existence of dogs, but more or less don't want them to exist. In my town, a dog is not to be on a leash longer than 6 feet off of the owner's property, for example. There is nowhere "sanctioned" to take dogs to run, if your yard is small, or if you have an apartment. Of course you have to pick up dog waste not on your property. Also, "nuisance barking" is ticketable, but that doesn't seem to be enforced very much, judging by the block that I think of as "the gauntlet", as there are six or more dogs barking in houses anytime anybody is on that block. There don't seem to be laws like that if a child is misbehaving, and I firmly believe it's up to the parents or caregivers to train a child, much the same way owners are expected to train their dogs. How else will either learn how to behave in public?
Dogs are everywhere. Elka is my first dog, but I've known a dozen or more in the course of my life. I see them on the street all the time, and in parks. I don't remember being specifically taught how to behave around a dog; maybe I just knew somehow (though I doubt it). I run into a lot of people, and kids, who have no idea how to "meet" a new dog, though, and it really interferes with walks and basic interactions.
Today, Elka and I were out on our walk, and she was heeling very well. There were some kids, probably around ten years old, in front of a school, working on the garden. I moved over and moved Elka over, saying something about "it's not nice to sneak up on people". One boy who clearly did not like dogs but was taught about them, stood tall and stood still. The next boy, less than a foot away from us, looked at Elka and RAN away. Which, comically but not, scared my dog. She bolted sideways, and then came back to heel when I asked her, and, perhaps insensitively, I exclaimed "NEVER run from a dog! Running can make a dog want to bite you. Never run." He hid behind two teachers, who kept moving to put themselves between Elka and him, which is all very sensitive and well and good, but Elka was freaked, and the kid clearly did not learn the lesson. He learned that if you run, adults will protect you. A dog will not always be controlled in the manner that Elka is.
So, dog manners, for the human side of things, since we owners concentrate so hard on the dog side.
1. Do not run if you are afraid of a dog. "Be a tree" is a common way of saying it. Stand up still, stand up straight and tall, and do not stare at the dog. You might get sniffed, but you won't be very interested.
2. If you are interested in meeting a dog, ask the owner first. Do not sneak up behind the dog and pet her back. Do not put your face in the dog's face.
3. If the owner says you can meet/pet the dog, put your hand out for the dog to sniff. If the dog sniffs you and does not then move away, pet the dog's neck or side. A lot of dogs don't like strangers touching their heads. Would you?
4. If the owner says no, that's that. Don't keep trying. Don't sneak up on the dog. It might be for your own safety, and it might be for the dog's comfort, but the reason doesn't matter. Respect the owner's wishes.
5. Don't run.