I know what you mean, Grandma70s, but things like smoking, and to some extent drinking and driving were once normalised, but are now socially unacceptable because of a change in public attitude, brought about by changes in the law. Yes, people still do smoke where they shouldn't, and drive after drinking, but not to anything like the extent that used to be considered ok.
If hitting children is made illegal, more authoritarian parents (perhaps more likely to use it as discipline?) might refrain because they believe in doing what they are told, and not wanting to break the law. If it's illegal, more people might speak out about it, and challenge parents whacking children in shops or discuss things with friends.
I think that changing the language around it would help, too. Having special words for violence towards children is very unhelpful. People even say that there is a difference between 'smacking' and 'hitting'. I assume they mean the intent is different (but even then, I'd argue that the intent is to cause pain in both cases) but the act is exactly the same. Calling it assault, or hitting would show it for what it is.