<script type="text/javascript" language="javascript"> function you() { var a = document.getElementsByTagName('input')[0]; var b = a.value; alert(b); } </script> <input type="text" /><br /> <input type="button" onclick="you();" value="Показать" />