Scripts in HTML documents - World Wide Web Consortium (W3C)
18.1 Introduction to scripts A client-side script is a program that may accompany an HTML document or be embedded directly in it. The program executes on the client's machine when the document loads, or at some other time such as when a link is activated....