How can HTML pages be integrated into PHP pages using menus?

To integrate HTML pages into PHP pages using menus, you can create a PHP file that includes the menu structure using HTML and then use PHP include function to include the desired HTML page based on the menu selection.

<?php
$menu = $_GET['menu'];

include('header.php');

switch($menu) {
    case 'home':
        include('home.html');
        break;
    case 'about':
        include('about.html');
        break;
    case 'contact':
        include('contact.html');
        break;
    default:
        include('home.html');
}

include('footer.php');
?>