Skip to content

Conversation

vera-ju
Copy link
Contributor

@vera-ju vera-ju commented Oct 9, 2025

No description provided.

<listitem>
<para>
Name of a file to be checked.
Name of a local file to be checked. Remote URLs are not supported.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it not say URIs? Also, what is the source of this information?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be completely honest, I'm not a PHP developer — I just came across this issue during Hacktoberfest.

From my point of view, there are three indicators that confirm this is correct:

  1. The open issue states it very clearly: (Improve finfo_file documentation to state that the file must be local #4803)
    “Suggested improvement: Clearly mention in the documentation that $filepath must be a local file and remote URLs are not accepted.”

  2. I asked ChatGPT about it, and it confirmed the same.

  3. A PHP colleague double-checked it and tested the function with an external URL — it didn’t work. However, using a local file worked correctly.

But if you don’t want to have it written that way in the documentation, feel free to just decline the PR.

Of course, I don’t want anything “incorrect” to be added either.
If you’d like, you can double-check it yourselves and adjust the wording however you think fits best 🙂

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know why it doesn't work with remote files, because it does use streams. Perhaps someone else more knowledge can review this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants