| 
 
 
 | 
 
	
	| 
				
					| HTML 4.0 Event Attributes |  
 
 
 
		
			| 
			New to HTML 4.0 is the ability to let HTML events trigger actions in the browser,
			like starting a JavaScript when a user clicks on an HTML element.A D V E R T I S E M E N T
 Below is a list
			of attributes that can be inserted into HTML tags to define event actions.
 |  
 
 
 
		
			| 
				Window Events
			 |  
			| Only valid in body and frameset elements. |  
			| 
					
					| Attribute | Value | Description |  
					| onload | script | Script to be run when a document loads |  
					| onunload | script | Script to be run when a document unloads |  |  
 
 
 
		
			| 
				Form Element Events
			 |  
			| Only valid in form elements. |  
			| 
					
					| Attribute | Value | Description |  
					| onchange | script | Script to be run when the element changes |  
					| onsubmit | script | Script to be run when the form is submitted |  
					| onreset | script | Script to be run when the form is reset |  
					| onselect | script | Script to be run when the element is selected |  
					| onblur | script | Script to be run when the element loses focus |  
					| onfocus | script | Script to be run when the element gets focus |  |  
 
 
 
		
			| 
				Keyboard Events
			 |  
			| Not valid in base, bdo, br, frame, frameset, head, HTML, iframe, meta,
				param, script, style, and title elements. |  
			| 
					
					| Attribute | Value | Description |  
					| onkeydown | script | What to do when key is pressed |  
					| onkeypress | script | What to do when key is pressed and released |  
					| onkeyup | script | What to do when key is released |  |  
 
 
 
		
			| 
			Mouse Events
			 |  
			| Not valid in base, bdo, br, frame, frameset,
				head, HTML, iframe, meta, param, script, style, title elements. |  
			| 
					
					| Attribute | Value | Description |  
					| onclick | script | What to do on a mouse click |  
					| ondblclick | script | What to do on a mouse double-click |  
					| onmousedown | script | What to do when mouse button is pressed |  
					| onmousemove | script | What to do when mouse pointer moves |  
					| onmouseout | script | What to do when mouse pointer moves out of an element |  
					| onmouseover | script | What to do when mouse pointer moves over an element |  
					| onmouseup | script | What to do when mouse button is released |  |  
 Be the first one to comment on this page.  
 
 
 
 Share And Enjoy:These icons link to social bookmarking sites where readers can share and discover new web pages.
 
 
	Keywords:HTML table attributes, HTML tag list attributes, HTML form attributes,
					HTML elements
	 |  | 
	
	
		| HTML Quizzes |  
		|  |  
		| XML Quizzes |  
		|  |  
		| Browser Scripting Quizzes |  
		|  |  
		| Server Scripting Quizzes |  
		|  |  
		| .NET (dotnet) Quizzes |  
		|  |  
		| Multimedia Quizzes |  
		|  |  
		| Web Building  Quizzes |  
		|  |  
		| Java Quizzes |  
		|  |  
		| Programming Langauges Quizzes |  
		|  |  
		| Soft Skills Quizzes |  
		|  |  
		| Database Quizzes |  
		|  |  
		| Operating System Quizzes |  
		|  |  
		| Software Testing Quizzes |  
		|  |  
		| SAP Module Quizzes |  
		|  |  
		| Networking Programming Quizzes |  
		|  |  
		| Microsoft Office Quizzes |  
		|  |  
		| Accounting Quizzes |  
		|  |  |