HTML tags

This is the test P. It has a class, a dir, an id and a title.

To fully support these properties, a browser must make a visible change in the element's layout.

var x;
function init () {
	x = document.getElementById('test');
}

.red {color: #cc0000;}

.blue {color: #0000cc;}

#nottest {background-color: #999999;}

Test alert(x.className)
Test alert(x.dir)
Test alert(x.id)
Test alert(x.title)
Test x.className = 'blue'
Test x.dir = 'rtl'
Test x.id = 'nottest'
Test x.title = 'This is a P'