How can PHP be used to display the current DJ playing on a web radio?

To display the current DJ playing on a web radio using PHP, you can create a PHP file that retrieves the current DJ's name from a database or a text file where it is stored. Then, you can use PHP to echo out the DJ's name on your webpage.

<?php
// Assuming the DJ's name is stored in a text file called current_dj.txt
$current_dj = file_get_contents('current_dj.txt');

echo "Current DJ: " . $current_dj;
?>