When I go to http://www.kambariokas.eu/prideti.php, I get an error $(“#nav”).spasticNav is not a function.
In other pages this script works perfectly, but this isn’t a script for validation. Maybe you have suggestions how to solve this?
Here is code:
<script type="text/javascript">
$('#nav').spasticNav();
$(document).ready(function(){
$.validator.addMethod("username", function(value, element) {
return this.optional(element) || /^[a-z0-9\_]+$/i.test(value);
}, "Username must contain only letters, numbers, or underscore.");
$("#skelbimas").validate();
});
</script>
It’s because $(“#nav”).spasticNav is not a function. That is, you haven’t defined it anywhere.
I presume it should be defined in the file http://www.kambariokas.eu/%20dizainas/js/jquery.spasticNav.js but that returns a 404 error. Hence your spasticNav function is never defined anywhere.
Edit: remove the extra space before dizainas to correct the script location.