"Never talk to a lady like that" "Watch your mouth. There are ladies present." Why does society want men to watch what they say in front of women?

I'm genuinely curious. Please be as honest and open as possible. Do you think this is good or bad for society? Ladies, do you like it this way?
"Never talk to a lady like that" "Watch your mouth. There are ladies present." Why does society want men to watch what they say in front of women?
Post Opinion