I have php code bellow, I want to write a script to read option value from drop-down list and put each value in the input box when I change the selection. Please, help.
<html>
<head>
<!-- Load jQuery from Google's CDN -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script>
<script>
//I want to write a script that will read the selected value and put in the input box
</script>
</head>
<body>
<?php
for ($i=0;$i<7;$i++)
{
?>
<select id='select$i'>
<option value="1">Option1</option>
<option value="2">Option2</option>
<option value="3">Option3</option>
</select>
<input type="text" name="name" id="inputoption$i" />
<?php }?>
<br />
</body>
</html>