JavaScript Elements and Embed Objects

JavaScript Elements and Embed Objects In this JavaScript tutorial, you will learn about browser objects – elements and embed, properties of elements object, length, type, embed object, properties of embed object along with syntax and examples. elements object: The elements object is used in JavaScript to access all form elements such as fields or buttons that are present or embedded within a form. Since each element inside the form is stored as an array element within the array elements[], the user can make use of the loop concept to access… Read More

JavaScript OnError Event

JavaScript OnError Event In this JavaScript tutorial, you will learn about onerror event, how to use onerror event along with syntax and example. Using onerror event: The onerror event fires when a page has a script error. This onerror event occurs in JavaScript when an image or document causes an error during loading. This does not mean that it is a browser error. This event handler will only be triggered by a JavaScript error, not a browser error. The general syntax of onerror event is as follows: onerror=functionname() function functionname(msg,file_loc,line_num)… Read More