<html>
<head>
<script>
window.onload = function() {
document.getElementById('text_id').focus();
};
</script>
</head>
<body>
<p>Some text so the document is ready for input.</p>
<input type="text" id="text_id">
</body>
</html>