D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
markniuj
/
bazmeasar.com
/
admin
/
Filename :
speaker.php
back
Copy
<?php include "../config.php"; // Retrieve the selected speaker from the query string if (isset($_GET['speaker'])) { $selected_speaker = urldecode($_GET['speaker']); // Query to select audio records for the selected speaker $query = "SELECT * FROM audio_files WHERE speaker = '$selected_speaker'"; $result = $conn->query($query); // Store audio records in an array $audio_records = []; if ($result && $result->num_rows > 0) { while ($row = $result->fetch_assoc()) { $audio_records[] = $row; } } } else { echo "Invalid speaker selection."; $conn->close(); exit(); } // Close the database connection $conn->close(); ?> <!DOCTYPE html> <html> <head> <title><?php echo $selected_speaker; ?></title> <meta charset="UTF-8"> <!-- responsive meta --> <meta name="viewport" content="width=device-width, initial-scale=1"> <!-- For IE --> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <!-- Module css --> </head> <body> <h1><?php echo $selected_speaker; ?></h1> <!-- List audio records for the selected speaker with links to details pages --> <ul> <?php foreach ($audio_records as $record) { $audio_id = $record["id"]; $english_title = $record["english_title"]; $urdu_title = $record["urdu_title"]; ?> <li> <a href="details.php?id=<?php echo $audio_id; ?>"> <?php echo $english_title; ?> ( <?php echo $urdu_title; ?> ) </a> </li> <?php } ?> </ul> </body> </html>