What are some best practices for including files in PHP to avoid path issues?
When including files in PHP, it's important to use absolute paths to avoid path issues. One way to do this is by using the `__DIR__` magic constant, which represents the directory of the current script. By concatenating `__DIR__` with the relative path to the file you want to include, you can ensure that the file is always included correctly, regardless of the script's location.
include __DIR__ . '/path/to/file.php';