I am using the Globalize jQuery plugin to have globalization (correct number and date formats) on the client side in my MVC website. So I have downloaded that plugin and included the following javascript files after the validation js files themselves (I have tried putting the Globalize file before as well without any luck):
<script src="/Scripts/globalize.js"></script>
<script src="/Scripts/jquery.validate.globalize.min.js"></script>
<script src="/Scripts/globalize/globalize.culture.da-DK.js"></script>
But when run the application, I get the error
Globalize.addCultureInfo is not a function
I cannot figure out what the reason is
According to the documentation of the Globalize library itself, this function has been removed in the 1.x version. This function was exist in the versions 0.x
This method is replaced by
Globalize.loadMessages( json )
. If you were using it for anything except message translations, you may also need to useGlobalize.load
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With