How do I perform the following?

Here’s my code:

<div class="scrollit">
        <table id="rank-table">
<thead>
<tr>
                <th>Select</th>
<th scope="col"><a href="#" class="sort-by">Sort Order</a></th>
<th scope="col"><a href="#" class="sort-by">Rank Name</a></th>
<th scope="col"><a href="#" class="sort-by">Level</a></th>
<th scope="col"><a href="#" class="sort-by">Fee</a></th>
<th scope="col"><a href="#" class="sort-by">Minimum Classes at Rank</a></th>
<th scope="col"><a href="#" class="sort-by">Minimum Time at Rank</a></th>
            </tr>
</thead>
<tbody>
<tr>
            <?php
                while($rows=$result->fetch_assoc())
                {
            ?>
            <tr>
                <td><input type="checkbox" style="vertical-align:middle" name='selectedRow[]' value='" . $row['id'] . "'></td>
                <td><?php echo $rows['sortorder'];?></td>
                <td><?php echo $rows['rankname'];?></td>
                <td><?php echo $rows['level'];?></td>
                <td><?php echo $rows['fee'];?></td>
                <td><?php echo $rows['min_classes_at_rank'];?></td>
                <td><?php echo $rows['min_time_at_rank'];?></td>
            </tr>
            <?php
                }
            ?>
            </tbody>
        </table>
            </div>

        </div>

This is what it actually looks like:


The image describes what I would like to happen. I already have this built, I just can’t figure out how to pass the data to the edit page and then fill the input fields with the data from the selected row and then update the data with the update button in the form. The layout is already the way I would like it, I just need the functionality. Is there any way to do this? When you click the “Edit Selected Rank Group”, it will pass the data from the selected row.