Each culture has its own mores for interpersonal relationships, but one of the basic rules for interaction that has remained true across cultures is the importance of treating others the way one wants to be treated. Following that principle is more difficult than it sounds, but if one looks at the mistakes that people have made in treating each other throughout history, they all violate that principle.
When one decides to treat others the way that one wants to be treated, there is a lot of self-discipline that comes into play. First of all, the desire for revenge is something that one can no longer indulge. If someone receives an offense, one of the first impulses is to retaliate against the person who committed that offense; however, no one wants to be the object of revenge, so acting in accordance with this principle means working to find common ground and forgive.
Some of the ancient Greek tragedies revolve around people's unwillingness to put themselves in another's shoes when making decisions involving that person. For example, Aeschylus' play "Agamenon" involves a Greek king sacrificing his daughter so that he can get the winds he needs to sail to fight in the Trojan War. Simply putting himself in his daughter's or his wife's shoes might well have helped him make a more ethical decision.