title: How to create submit form in a row and relate input to that row?
body: <p><strong>Hey Guys, I have a question for you.</strong></p>
  
  <p>Imagine that I wanted to be able to keep track of how many miles I've ran every week, so that I could
  compare it to the goals I've set for each week. So i've created this table by the use of mysql_fetch_row.</p>
  
  <pre><code>$result=mysql_query("SELECT * FROM randomtable ORDER BY week ASC");
  
  echo "&lt;Table id='result' cellspacing='0'&gt;
      &lt;tr class='toprow'&gt;
      &lt;th&gt;Week&lt;/th&gt;
      &lt;th&gt;Goal&lt;/th&gt;
      &lt;th&gt;Actual Number of Miles&lt;/th&gt;
      &lt;/tr&gt;";
  
  while($row = mysql_fetch_row($result))
  {
      echo "&lt;tr class='standardrow'&gt;";
      echo "&lt;td&gt;$row[0]&lt;/td&gt;";
      echo "&lt;td&gt;$row[1]&lt;/td&gt;";
      echo "&lt;td&gt;&lt;form&gt;&lt;input method='post' type='number'&gt;&lt;/form&gt;&lt;/td&gt;";
      echo "&lt;/tr&gt;";
  }
  
  echo "&lt;/table&gt;";
  </code></pre>
  
  <p>This piece of code resultet in a table with 10 weeks with 10 goals - and a column for the actual number of miles. This column should include 10 input forms where the actual number of miles can be submitted. But how do I relate the input from the submit form to the row in which the submit form is positioned?
  The primary key is the week - so this would be the one to relate to. </p>
  
  <p>Hope you understand what my problem is:)</p>