К сожалению, я не смог вас полностью понять.Однако я намерен вам помочь.Что я думаю, что вам нужно:
Перенаправить пользователя на другую страницу с нажатием на значение
Ваш файл таблицы:
<table class="table table-bordered table-hover table-striped">
<thead>
<tr style="background-color:#f2f2f2">
<th>CRN</th>
<th>Section</th>
<th>Course Title</th>
<th>Start Time</th>
<th>End Time</th>
<th>Room Number</th>
</tr>
<?php
$db = new mysqli('localhost', 'root', '', 'mydb');
if($db->connect_error)
{
die("connection_failed:".$db->connect_error);
}
$sql="SELECT CRN, section, Crse_Title, Crse_Start_Time, Crse_End_Time, Room_Num from section";
$result = $db->query($sql);
if($result->num_rows > 0)
{
while ($row = $result->fetch_assoc())
{
echo "<tr>
<td><a href='course.php?id=".$row["CRN"]."' class='btn btn-md'>".$row["CRN"]."</a></td>
<td>". $row["section"]. "</td>
<td>". $row["Crse_Title"]. "</td>
<td>". $row["Crse_Start_Time"]."</td>
<td>". $row["Crse_End_Time"]."</td>
<td>". $row["Room_Num"]."</td>
</tr>";
}
//echo "</table>";
}
else
{
echo "0 result";
}
$db->close();
?>
</thead>
</table>
Файл курса:
<?php
if(isset($_GET['id']))
{
//is_numeric()
$id=(int) $_GET['id'];
print "Current Course ID : " . $id;
}
?>
Есть и другие способы (например, написание кода JavaScript)