<form onsubmit="return validate()" method="post"> Number: <input type="text" name="num1" id="num1" /> <br /> Repeat: <input type="text" name="num2" id="num2" /> <br /> <input type="submit" value="Submit" /> </form> Why are we using "return" here and why not just "validate()"?
8/25/2020 5:42:40 PM
Bishwajit Khanra1 Answer
New AnswerYou apply for a job in a company You submit your details to the company The company receives and do the certain validation and THEN RETURN YOU WHETHER You ARE SELECTED OR NOT (in this case validate())
Sololearn Inc.
535 Mission Street, Suite 1591Send us a message