in modern times, criminal laws in the muslim world were widely replaced by codes which were inspired by european laws. court procedures and legal education were also made similar to european practice. the constitutions of most muslim-majority states mention sharia in one way or another. however, the classical rules of sharia were preserved mostly in family laws. in earlier times, sharia was interpreted by independent scholars who often disagreed with each other, and all their opinions were never written down in one place. in the modern era, it was the government who controlled the laws. different states created their own legal codes, where the laws were clearly stated. the governments wanted to make family laws fit better in the modern world, but they still wanted people to view them as laws based on sharia. in order to do this, the scholars who wrote down these laws decided to pick and choose rules from the different legal opinions available in the classical books of law. when some of the laws they picked disagreed with the current norms of society, the government tried to solve this problem by creating additional court procedures. for example, when family laws in some states seemed to treat women unfairly to the population, the government created procedures that made it more difficult for men to take advantage of these laws in an unfair manner.