What is the correct syntax for generating a link in PHP that passes an ID for editing a specific database record?

When generating a link in PHP that passes an ID for editing a specific database record, you can use query parameters in the URL to pass the ID value. This ID can then be retrieved from the URL in the target page to identify the specific record to edit.

// Assuming $recordId contains the ID of the database record to be edited
$editLink = "edit_record.php?id=" . $recordId;
echo "<a href='$editLink'>Edit Record</a>";