How can I link Javascript and html? [on hold]

This is my html file
I want to create a registration form, and I want that after I have sent all the information, it does not matter if it is in the correct or incorrect form, click on the Register button, the line "sent successfully" will appear on the screen. I have seen many videos on YouTube and it is too complicated compared to my needs …