h2 (HTML4 & HTML5)

Heading Level 2.

Properties & Events

KeyDescriptionAvailability
alignDefines the alignment of the element.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
classCSS class assigned to the element.
chrome 1.0safari 1.0Firefox 1.0ie 1.0opera 1.0
dirDirection of the element text.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
disabledSpecifies whether or not the element is disabled.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
idUnique identifier for the element.
chrome 1.0safari 1.0Firefox 1.0ie 1.0opera 1.0
langLanguage code for the content of the element.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
languageScript language for the element.
chrome 1.0safari 1.0Firefox 1.0ie 3.0opera ??
styleInline style for the element.
chrome 1.0safari 1.0Firefox 1.0ie 1.0opera 1.0
tabindexPosition of the element in the tabbing order for the document.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
titleShort text description for the element.
chrome 1.0safari 1.0Firefox 1.0ie 1.0opera 1.0
onblurFires when the element loses focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onclickFires when the element is clicked.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
ondblclickFires when the element is double-clicked.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onfocusFires when the element receives focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onkeydownFires when a user presses down on a key while the element has focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onkeypressFires when a user presses a key or holds down the key while the element has focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onkeyupFires when a user releases a key while the element has focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onmousedownFires when a user clicks down on the mouse button while the element has focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onmousemoveFires when the mouse moves while the pointer over the element.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onmouseoutFires when the mouse pointer moves off of the element.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onmouseoverFires when the mouse pointer moves over the element.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0
onmouseupFires when the user releases the mouse button while the element has focus.
chrome 1.0safari 1.0Firefox 1.0ie 2.0opera 4.0

Examples having uses of: 'h2'

26 votes
16k views

HTML Headings

HTML headings are defined with the <h1> to <h6> tags.
2 votes
13k views

JavaScript Keywords list

JavaScript has many keywords some of them are currently in use and some of them are reserved for future use. We can not use the keywords for our general purpose.
1 votes
12k views

jQuery AJAX Introduction

The jQuery load method is a simple to use AJAX (Asynchronous JavaScript and XML.) function. That enables you to load ajax content with one line of code. AJAX is a technique for creating better and more interactive web applications and we at webgrid.com are using ajax with jQuery alot to make this web page better!
1 votes
11k views

CSS Absolute

With absolute positioning, an element can be placed anywhere on a page. In this example the heading has been placed 100px from the left of the page and 150px from the top of the page. It will remain in this position.
3 votes
10k views

HTML & CSS

Styling HTML elements with CSS (Cascading Style Sheet). CSS was introduced together with HTML 4, to provide a better way to style HTML elements.
3 votes
10k views

jQuery DOM Traversing

jQuery is a very powerful tool which provides a variety of traversal methods to help us select elements in a document randomly as well as in sequential method. In other words, we can say that most of the traversing methods are used to find elements from the documents.
0 votes
10k views

CSS Grouping

Grouping is the method to group the selectors which have same property. It minimizes the code. We write the selectors by separating them using comma.
0 votes
10k views

CSS Text Color

Shows how to set text colors on different elements.
1 votes
9k views

jQuery Event Introduction

Introduction to jQuery and how to attach a handler to one or more events for all elements that match the selector.
3 votes
9k views

jQuery Attributes

Some of the most basic components we can manipulate when it comes to DOM elements are the properties and attributes assigned to those elements
0 votes
9k views

JavaScript switch statement with number

The switch statement is used to select one statement from the many blocks. This is used on place of nested if…else. If there are number of if..else statements then we should use switch.
1 votes
8k views

JavaScript Comparison Operator ==

JavaScript "==" is equal to operator.
3 votes
8k views

JavaScript if and else

JavaScript if…else is a conditional statement that is used to check wether a condition is true or false to take a decision.
4 votes
8k views

jQuery ajaxStart & ajaxComplete

jQuery ajaxStart and ajaxComplete are two functions are very useful to show the graphics while the data is loading from server. The ajaxStart method works while the server fullfilling the service asked to it. The ajaxComplete method is called when the server fulfilled the request.
0 votes
8k views

Javascript Guidelines

There are some guidelines which must be remembered while coding in javascript. 1) Javascript is case-sensitive language. 2) JavaScript ignores extra white spaces. 3) You can break the line of code.
0 votes
2k views

JavaScript onselect Event

Triggers whenever you Select/Highlight some text within textbox or textarea.
1 votes
2k views

CSS Text Colors

This example uses an internal CSS Style Sheet sets the body text to blue, and changes H1 to green (#9AFE2E) and H2 to red (#FF0000).
0 votes
2k views

jQuery DOM Traversing and locating elements

Jquery traversing methods can be used to locate all the descendent elements of a particular type of elements.
0 votes
1k views

CSS Align

The text-align property specifies the horizontal alignment of text in an element.
0 votes
1k views

HTML Align

If you wish to change the horizontal location of your elements you may do so using the align attribute. You may align elements left, right, or center.
0 votes
1k views

JavaScript switch statement with string

The switch statement is used to select one statement from the many blocks. This is used on place of nested if…else. If there are number of if..else statements then we should use switch.
1 votes
1k views

CSS Multiple Shadows

We can apply multiple shadows of the box or text at the same HTML element.
0 votes
1k views

JavaScript nested if and else

This statement allows us to select one statement among many statements.It is also called nested if….else.
0 votes
1k views

CSS Display none

CSS display property specifies how an element is displayed. The 'none' property hides the elements.
0 votes
1k views

jQuery DOM Traversing and filtering

Most of the JQuery Traversal Methods do not modify the jQuery object and they are used to filter out elements from a document based on given conditions. The filter( selector ) method can be used to filter out all elements from the set of matched elements that do not match the specified selector(s).
1 votes
1k views

jQuery Selectors Types

jQuery selectors allow you to select and manipulate HTML elements as a group or as a single element.
0 votes
1k views

JavaScript Keywords example

A small example displaying the usage of two JavaScript keywords in a code block.
0 votes
1k views

Minimise inline JavaScript

Almost all JavaScript code should be in separate JavaScript files. There should be the smallest possible amount of JavaScript inline in the HTML code of pages.
0 votes
1k views

JavaScript Comparison Operator <

JavaScript < is less then operator.
0 votes
1k views

When JavaScript is not supported

While most current browsers understand Javascript a lot of the early browsers did not. The current browsers also allow Javascript to be turned off and some people do this. What this means is that not all of the visitors to your page will see the effects of the JavaScript on your page. We need to make sure that these visitors can use our site even without JavaScript.
0 votes
1k views

JavaScript Comparison Operator !=

JavaScript "==" is not equal to operator.
0 votes
1k views

JavaScript Comparison Operator ===

JavaScript "===" is exactly equal to (value and type) operator.
0 votes
1k views

Minimise the number of JavaScript files

Try not to use too many different JavaScript files. Each separate file that the browser has to load incurs an overhead. You may consider to merge and minimise JavaScript files before you publish your website. This to reduce the bandwidth usage and lower webpage load time.
0 votes
1k views

JavaScript Comparison Operator >=

JavaScript > is greater or equal to operator.
0 votes
1k views

JavaScript Comparison Operator <=

JavaScript > is less or equal to operator.
0 votes
1k views

JavaScript Comparison Operator >

JavaScript > is greater then operator.
0 votes
1k views

JavaScript Logical Operator || (or)

The || (or operator) logical operator are used to determine the logic between variables or values.
0 votes
1k views

JavaScript Logical Operator && (and)

The && (and operator) logical operator are used to determine the logic between variables or values.
0 votes
1k views

JavaScript Logical Operator ! (not)

The ! (not operator) logical operator are used to determine the logic between variables or values.
0 votes
0 views

colorful texts

Shows how to set text colors on different elements.12345