I decided it this way because my code is a little different, it may be useful for other people. My original code was as follows.
<form id="enrollstudentform" onsubmit="return enrollStudents()"> ... </form>
My js function looked like
function enrollStudents() {
I had to pass a parameter event in a function call and get it in a function .
<form id="enrollstudentform" onsubmit="return enrollStudents(event)"> ... </form>
js code:
function enrollStudents(event) {
Hope this helps.
Andres Ramos Oct 19 '16 at 17:17 2016-10-19 17:17
source share