What best practices should be followed when including external files or scripts in PHP to avoid syntax errors or unexpected behavior?

When including external files or scripts in PHP, it is important to follow best practices to avoid syntax errors or unexpected behavior. One common issue is including a file multiple times, which can lead to redeclaration errors. To prevent this, you can use the `require_once` or `include_once` functions instead of `require` or `include` to ensure that the file is only included once.

<?php
require_once 'external_file.php';
?>