What are some common reasons for PHP include not functioning as expected when attempting to outsource header and footer sections?

One common reason for PHP include not functioning as expected when outsourcing header and footer sections is incorrect file paths. Make sure that the file paths specified in the include statement are correct relative to the current file location. Additionally, check for any errors in the included files that may be causing the issue.

<?php
// Include header
include 'path/to/header.php';

// Your page content here

// Include footer
include 'path/to/footer.php';
?>