<head>
<style>
DIV {
position: absolute;
height: 100px;
width: 200px;
}
</style>
</head>
<body>
<div id="elem" style="background: #ff0;"> </div>
<script>
document.getElementById('elem').onclick = function(){
var newDiv = document.createElement('div');
newDiv.style.background = '#f00';
newDiv.style.cursor = 'pointer';
newDiv.innerHTML = ' ';
document.body.appendChild(newDiv);
*!*this.style.cursor = 'pointer';*/!*
};
</script>
</body>