

When writing a document is required, then the use of another essential feature: the functions.Ī function is an instruction set, which should only be performed when the function is activated. To prevent the two lines are written on the same line is used to HTML tag to make a line break. The idea of the above example is to write two lines. For example:ĭocument.write (“This line appears the result of” + The lines written by this method will appear on the screen point where the command is entered. The lines written in this way, can contain text, HTML and JavaScript expressions commands. JavaScript allows the programmer to write lines within a page (document) through the write method. onsubmit – Occurs when a Submit type button receives a click of the mouse.onselect – Occurs when the object is selected.onmouseover – Occurs when the mouse pointer passes over the object.Valid for Buton objects, Checkbox, Radio, Link, Reset and Submit onclick – Occurs when the object receives a Click of the Mouse.Valid for objects Text, Select and Textarea onfocus – Occurs when the object receives focus.onblur – Occurs when the object loses the focus, irrespective of the existence change.onchange – Occurs when the object loses focus and there was a change of content.

