What is the best practice for passing values from one page to another in PHP when clicking on a link within a table?

When passing values from one page to another in PHP when clicking on a link within a table, the best practice is to use query parameters in the URL. This allows you to pass values through the URL and retrieve them on the destination page using the $_GET superglobal array.

// Source page with table
<table>
    <tr>
        <td>Value 1</td>
        <td><a href="destination.php?value=value1">Link</a></td>
    </tr>
    <tr>
        <td>Value 2</td>
        <td><a href="destination.php?value=value2">Link</a></td>
    </tr>
</table>

// Destination page
<?php
if(isset($_GET['value'])){
    $value = $_GET['value'];
    echo "Value passed: " . $value;
}
?>