# Request #44392: getFilePointer() for Childs of SplFileObject

- Thread: https://externals.io/message/64205
- Original archive: https://news-web.php.net/php.internals/64205
- Started by Levi Morrison on 2012-12-09T01:31:37+00:00
- Messages: 1
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · RFCs at https://externals.io/rfc.md · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #64205 — Levi Morrison — 2012-12-09T01:31:37+00:00

URL: https://externals.io/message/64205#64205

A copy of the feature request description
(https://bugs.php.net/bug.php?id=44392):

It would be nice if it would be possible to get the underlying
resource handle of an SplFileObject to be able to add stream filters
on the file. Sadly the URI parser in PHP seems to be broken and URIs
with filters like
php://filter/read=convert.iconv.ISO-8859-15/UTF-8/resource=... cannot
be used (encoding the slash doesn't work either (%2F)) therefore it
would be nice if one could access the underlying resource handle f.e.
by providing a protected $fp in SplFileObject one could use in a child
class then and do the `stream_filter_append()` there.

---

I think this feature would prove to be useful.  I also see no reason
why the SplFileObject can't have this as a public method.  Any
objections to this?
