No, corporal law is not right, because there are other ways to discipline. For parents, or even for a government, there are many other ways available to punish someone than corporal punishment. Using corporal punishment sends the message that violence if acceptable. Those who are being punished will become violent themselves because they see violence used.
Although the Old Testament merits "an eye for an eye" as a form of punishment, modern thought believes that corporal punishment is not an effective way to deter misdeeds. The penal system is intended to be a rehabilitative process, and physically violent punishments cause more damage than they repair. Other forms of punishment should be preferred.