<html>
<head>
<script>
function content(){
alert (this.innerHTML);
}
</script>
</head>
<body>
<div onclick='content(this)'>some text here</div>