Is there a way to tunnel require/include through a userspace streams
filter?
What I want to do is write a userspace streams filter and register that
as some kind of default filter through which require/include read their
files.
Thanks,
Sebastian
--
Sebastian Bergmann http://www.sebastian-bergmann.de/
GnuPG Key: 0xB85B5D69 / 27A7 2B14 09E4 98CD 6277 0E5B 6867 C514 B85B 5D69
include('php://filter/string.toupper/resource=/foo/bar/baz');
Filters can be stacked, set on the read or write chains individually (though
the latter hardly matters for include/require), and resource can be another
wrapper, not just a local file.
Ref: http://www.php.net/wrappers.php
-Sara
----- Original Message -----
From: "Sebastian Bergmann" sb@sebastian-bergmann.de
Newsgroups: php.internals
To: internals@lists.php.net
Sent: Tuesday, March 07, 2006 11:44 PM
Subject: "Tunnelling" require/include through userspace streams filter
Is there a way to tunnel require/include through a userspace streams
filter?What I want to do is write a userspace streams filter and register that
as some kind of default filter through which require/include read their
files.Thanks,
Sebastian--
Sebastian Bergmann http://www.sebastian-bergmann.de/
GnuPG Key: 0xB85B5D69 / 27A7 2B14 09E4 98CD 6277 0E5B 6867 C514 B85B 5D69
Sara Golemon schrieb:
include('php://filter/string.toupper/resource=/foo/bar/baz');
I do not want to change the include/require calls but instead set up
a filter for the standard ones.
--
Sebastian Bergmann http://www.sebastian-bergmann.de/
GnuPG Key: 0xB85B5D69 / 27A7 2B14 09E4 98CD 6277 0E5B 6867 C514 B85B 5D69
Oops, missent this the first time using my personal address... Sebastian:
Please don't reply-all to that one, I'm trying to keep that off the list.
I do not want to change the include/require calls but instead set up
a filter for the standard ones.
Ah... I can see use for that.
I'm actually about to do some (overdue) fixes/stabilizations to
php6-unicode-streams. Once that's all settled, I'll come back to this and
look at adding something along the lines of: stream_filter_auto() or
whatever.
-Sara
Sara Golemon schrieb:
Ah... I can see use for that.
I expected nothing else from you ;-)
I'll come back to this and look at adding something along the lines
of: stream_filter_auto() or whatever.
Great, and thanks in advance,
Sebastian
--
Sebastian Bergmann http://www.sebastian-bergmann.de/
GnuPG Key: 0xB85B5D69 / 27A7 2B14 09E4 98CD 6277 0E5B 6867 C514 B85B 5D69