PHP $_GET from HTML table row
<p>so I have a table of data that gets produced in PHP. What I was hoping for, would be to have a button to view that specific piece of data in that table row, i.e. press 'view graph' and it uses the $_GET method to take the id of the value of that row, and use it to display data. This instead of creating an individual page for each graph, so it just produces the relevant data for that page.</p>

<p>At the moment, my code looks like this:</p>

<pre><code>if ($id==$server_id){
    echo("&lt;tr&gt;&lt;td&gt;".$row2['hostname']."&lt;/td&gt;
    &lt;td&gt;&lt;a href=".$url."&gt;".$row['name']."&lt;/a&gt;&lt;/td&gt;
    &lt;td&gt;&lt;span class='label label-$alerting'&gt;"
    .$row['capacity'].
    "%&lt;/span&gt;&lt;/td&gt;
    &lt;td&gt;&lt;input type='submit' value='View Graph'&gt;&lt;/td&gt;
    &lt;/form&gt;&lt;/tr&gt;");
}
</code></pre>

<p>How would I get the id/name for each row to parse into a new page?</p>