From e45037c60d4bd62334536961cc5e6adfeca17274 Mon Sep 17 00:00:00 2001 From: Sara Golemon Date: Sat, 13 Dec 2003 21:43:23 +0000 Subject: [PATCH] Add file:// section Refactor ftp:// "supported" section. Add mkdir/rmdir lines to all "supported" sections. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@146388 c90b9560-bf6c-de11-be94-00142212c4b1 --- appendices/wrappers.xml | 149 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 138 insertions(+), 11 deletions(-) diff --git a/appendices/wrappers.xml b/appendices/wrappers.xml index 18fe564cbc..32f08f1050 100644 --- a/appendices/wrappers.xml +++ b/appendices/wrappers.xml @@ -1,5 +1,5 @@ - + List of Supported Protocols/Wrappers @@ -11,6 +11,90 @@ stream_wrapper_register. +
+ Filesystem + All versions of PHP. Explicitly using file:// since PHP 4.3.0 + + + /path/to/file.ext + relative/path/to/file.ext + fileInCwd.ext + C:/path/to/winfile.ext + C:\path\to\winfile.ext + \\smbserver\share\path\to\winfile.ext + file:///path/to/file.ext + + + + file:// 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. + + + + + Wrapper Summary + + + + Attribute + Supported + + + + + Restricted by allow_url_fopen. + No + + + Allows Reading + Yes + + + Allows Writing + Yes + + + Allows Appending + Yes + + + Allows Simultaneous Reading and Writing + Yes + + + Supports stat + Yes + + + Supports unlink + Yes + + + Supports rename + Yes + + + Supports mkdir + Yes + + + Supports rmdir + Yes + + + +
+
+
+
HTTP and HTTPS PHP 3, PHP 4. https:// since PHP 4.3.0 @@ -120,6 +204,14 @@ foreach(stream_get_meta_data($fp) as $response) { Supports rename No + + Supports mkdir + No + + + Supports rmdir + No + @@ -246,49 +338,68 @@ foreach(stream_get_meta_data($fp) as $response) { Wrapper Summary - + Attribute - Supported + PHP 4 + PHP 5 Restricted by allow_url_fopen. Yes + Yes Allows Reading Yes + Yes Allows Writing - - Yes (Prior to PHP 5.0.0: new files only. - PHP 5.0.0 and later: overwrite allowed - with context option) - + Yes (new files only) + Yes (new files/existing files with overwrite) Allows Appending - Yes (PHP 5.0.0 or later) + No + Yes Allows Simultaneous Reading and Writing No + No Supports stat No + + filesize, filetype, + file_exists, is_file, + and is_dir elements only. + Supports unlink - Yes (PHP 5.0.0 or later) + No + Yes Supports rename - Yes (PHP 5.0.0 or later) + No + Yes + + + Supports mkdir + No + Yes + + + Supports rmdir + No + Yes @@ -523,6 +634,14 @@ file_set_contents("php://filter/write=string.rot13/resource=example.txt","Hello Supports renameNo + + Supports mkdir + No + + + Supports rmdir + No +
@@ -604,6 +723,14 @@ file_set_contents("php://filter/write=string.rot13/resource=example.txt","Hello Supports rename No + + Supports mkdir + No + + + Supports rmdir + No +