title: applying onkeyup function simultaneously on multiple textboxes
body: <p>Suppose I have a column of 1+7 text box. Name of the first box is mm1 and the other boxes are respectively dd1, dd2, ...., dd7. I want to write a javascript function so that all the values in the textboxes dd1, dd2,...,dd7 are multiplied by N if I put N in the first textbox namely mm1. I can write the javascript function , but how to make its effect in all boxes simultaneously? I have tried the following code. But it can effect only one box depending on the value of $i. If we can create a loop for $i taking values 1 to 7, then perhaps the problem will be solved. Any clue please. </p>
  
  <pre><code>&lt;?php $i=3?&gt;
  &lt;input type="text" size="1" id="mm1" name="mm1" 
  maxlength="2"  onfocus="this.select()"    
  onkeyup="gft('dd&lt;?php echo $i?&gt;', 'mm1')"
  &gt;
  </code></pre>