Not only are STDIN, STDOUT, and STDERR only allowed for CLI programs, but they are not allowed for programs that are read from STDIN. That can confuse you if you try to type in a simple test program.
![]() |
|
||||||||||
|
Приложение M. List of Supported Protocols/WrappersThe following is a list of the various URL style protocols that PHP has built-in for use with the filesystem functions such as fopen() and copy(). In addition to these wrappers, as of PHP 4.3.0, you can write your own wrappers using PHP script and stream_wrapper_register(). FilesystemAll versions of PHP. Explicitly using file:// since PHP 4.3.0
Filesystem is the default wrapper used with PHP and represents the local filesystem. When a relative path is specified (a path which does not begin with /, \, \\, or a windows drive letter) the path provided will be applied against the current working directory. In many cases this is the directory in which the script resides unless it has been changed. Using the CLI sapi, this defaults to the directory from which the script was called. With some functions, such as fopen() and file_get_contents(), include_path may be optionally searched for relative paths as well.
List of Supported Protocols/Wrappers
jerry at gii dot co dot jp
17-Aug-2007 10:11
Not only are STDIN, STDOUT, and STDERR only allowed for CLI programs, but they are not allowed for programs that are read from STDIN. That can confuse you if you try to type in a simple test program.
sander at medicore dot nl
14-Jun-2007 04:25
to create a raw tcp listener system i use the following:
ben dot johansen at gmail dot com
25-Oct-2006 02:57
followup:
ben dot johansen at gmail dot com
29-Aug-2006 11:02
Example of how to use the php://input to get raw post data
ben dot johansen at gmail dot com
29-Aug-2006 12:33
In trying to do AJAX with PHP and Javascript, I came upon an issue where the POST argument from the following javascript could not be read in via PHP 5 using the $_REQUEST or $_POST. I finally figured out how to read in the raw data using the php://input directive.
heitorsiller at uol dot com dot br
07-Jul-2006 07:55
For reading a XML stream, this will work just fine:
opedroso at NOSPAMswoptimizer dot com
12-Apr-2006 11:07
php://input allows you to read raw POST data. It is a less memory intensive alternative to $HTTP_RAW_POST_DATA and does not need any special php.ini directives.
nyvsld at gmail dot com
27-Nov-2005 10:28
php://stdin supports fseek() and fstat() function call,
drewish at katherinehouse dot com
24-Sep-2005 11:50
Be aware that contrary to the way this makes it sound, under Apache, php://output and php://stdout don't point to the same place.
chris at free-source dot com
26-Apr-2005 12:52
If you're looking for a unix based smb wrapper there isn't one built in, but I've had luck with http://www.zevils.com/cgi-bin/viewcvs.cgi/libsmbclient-php/ (tarball link at the end).
nargy at yahoo dot com
24-Sep-2004 03:16
When opening php://output in append mode you get an error, the way to do it:
aidan at php dot net
27-May-2004 03:34
The contants:
lupti at yahoo dot com
29-Nov-2003 02:04
I find using file_get_contents with php://input is very handy and efficient. Here is the code:
sam at bigwig dot net
15-Aug-2003 08:02
[ Editor's Note: There is a way to know. All response headers (from both the final responding server and intermediate redirecters) can be found in $http_response_header or stream_get_meta_data() as described above. ] |