Unable to call function from after adding js file
I am new to this technology, I had created rules.js file in which i mentioned validate function which is used for required field validator for textarea. but after adding the js file in my html page i unable to call that function please let me know what i am doing wrong.
if (req==null || req=="")
If i add this function on the same HTML page, the after i don't face any problem to calling it, but i want to call it from source file.
<form id="registration" name="registration" method="POST" action="" onsubmit="return validate();">