I picked up a project that another developer built. He has some of the JavaScript on the actual php page which is making debugging difficult.
<button type="submit" onclick="doFunction(event)">Done</button>
I have tried to move it to a javascript file:
$( document ).ready(function() {
function doFunction(e){}
});
and removing it from the PHP page but now it's not firing. Why is it not working now and how do I fix it?