What is the difference between including a file using a full URL versus a relative path in PHP?

Including a file using a full URL in PHP can be less efficient and may cause security risks, as it requires an HTTP request to fetch the file from the server. On the other hand, using a relative path is more efficient and secure, as it directly accesses the file within the same server without making additional HTTP requests. It is recommended to use relative paths when including files in PHP to improve performance and security.

// Including a file using a relative path
include 'path/to/file.php';