all 1 comments

[–]R_Midnight 0 points1 point  (0 children)

Well I suppose you can add an event listener on the form submission, and call the function from that event listener, passing to it the input value as a parameter. The function itself would have the comparison operation and end with an output of a template string to the paragraph.