I think Dear Abby said this a long, long time ago. I've always remembered it and I use it frequently in therapy. "We teach people how to treat us." How do we do this?
By the way we treat ourselves. If we treat ourselves with respect we will be treated with respect. Likewise, if we disrespect ourselves, others will tend to do likewise. How does this look in the "real world" of human behavior?
A woman constantly sacrifices her own needs and desires for everyone around her. She doesn't rest when she is tired because her husband needs something done. She doesn't eat when she is hungry because she has to pick up the kids. She doesn't eat what she wants because the husband or the kids don't like it. She wears what pleases her husband, not what feels good to herself. She uses her free time to take care of an ailing parent who does not appreciate it. She drives the neighbor lady everywhere she needs to go to the point that she doesn't have enough gas left in the car to do her own errands. She hasn't had a medical checkup in years because she never has the time. She keeps meaning to sign up for the gym or that art class she wants to attend - but she never has the time. She never says "No" to anyone. What does this tell people? That her needs are unimportant. That her time is unimportant. That her life is at their disposal. So they take it. And she gives.
Consider what would happen if this woman started to respect herself, and her time, a bit more. She would say, "No, I cannot take you to the store today. I have a class to attend." "No, I can't run that errand right now, I have a doctor's appointment." "No, I can't come over today, I have to get some rest before the kids come home." How would the people in her life react?
I remember reading research about how our beliefs about ourselves affect how people perceive and treat us. It focused primarily on self-confidence, but could be applied to other beliefs. The study showed if a person is confident within themselves they can handle a situation, the people around them are confident they can too. If a person lacks confidence in their abilities, other people will too. People accept our beliefs about ourselves. If we believe we are unimportant, they will too. If we believe we are not good enough, they will too. And they will treat us accordingly.
I worked with a client who believed she was a human trash can. Molested at a young age, she grew up with the experience of having her body used to please someone else. She continued this pattern as an adult; drowning her body in alcohol, tossing it full of every kind of drug and allowing anyone to have sex with her. She never considered the possibility that if she didn't want to have sex, she shouldn't. Her body was at the disposal of others. When she stopped thinking of it as a trash can, she stopped allowing it to be used and abused. She stopped heaping it full of chemicals. She fed it good food, took it to yoga classes and used it to please herself, not others. As her beliefs about herself were reflected in how she treated herself she began to draw different kinds of people to her. As she began to respect herself, people who were able to respect her and treat her with dignity became more interested in her. Instead of users and manipulators she became interesting to people who were nurturing and caring. People who have respect for themselves are uncomfortable being with people who do not respect themselves. Likewise, misery loves company and people who have no respect for themselves are attracted to others like them.
The point? If you want to change how other people treat you, you first have to change how you treat yourself. They will either get with the new you, or exit your life and leave room for people who are healthier to come in.