How can the use of __DIR__ in PHP includes improve file path management?

Using __DIR__ in PHP includes can improve file path management by providing a reliable way to reference the directory of the current script. This helps avoid issues with relative paths when including files from different directories, ensuring that the correct files are included regardless of the script's location.

// Example of using __DIR__ in PHP includes
include __DIR__ . '/path/to/file.php';