Sophie

Sophie

distrib > PLD > ac > amd64 > media > dist > by-pkgid > dd8ef74e7a184506d40e4328053fb785 > files > 3976

php-manual-ro-20051028-1.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>php_stream_open_wrapper</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
REL="HOME"
TITLE="Manual PHP"
HREF="index.html"><LINK
REL="UP"
TITLE="Streams Common API Reference"
HREF="stream.common-api.html"><LINK
REL="PREVIOUS"
TITLE="php_stream_stat"
HREF="streams.php-stream-stat.html"><LINK
REL="NEXT"
TITLE="php_stream_read"
HREF="streams.php-stream-read.html"><META
HTTP-EQUIV="Content-type"
CONTENT="text/html; charset=ISO-8859-2"></HEAD
><BODY
CLASS="refentry"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
SUMMARY="Header navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Manual PHP</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="streams.php-stream-stat.html"
ACCESSKEY="P"
>Înapoi</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="streams.php-stream-read.html"
ACCESSKEY="N"
>Înainte</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><H1
><A
NAME="streams.php-stream-open-wrapper"
></A
>php_stream_open_wrapper</H1
><DIV
CLASS="refnamediv"
><A
NAME="AEN129647"
></A
><P
>    (no version information, might be only in CVS)</P
>php_stream_open_wrapper&nbsp;--&nbsp;Opens a stream on a file or URL</DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN129650"
></A
><H2
>Description</H2
>php_stream * <B
CLASS="methodname"
>php_stream_open_wrapper</B
> ( char * path, char * mode, int options, char ** opened)<BR
></BR
><P
>&#13;     <B
CLASS="function"
>php_stream_open_wrapper()</B
> opens a stream on the file, URL or
     other wrapped resource specified by <VAR
CLASS="parameter"
>path</VAR
>.  Depending on
     the value of <VAR
CLASS="parameter"
>mode</VAR
>, the stream may be opened for reading,
     writing, appending or combinations of those. See the table below for the different
     modes that can be used; in addition to the characters listed below, you may
     include the character 'b' either as the second or last character in the mode string.
     The presence of the 'b' character informs the relevant stream implementation to
     open the stream in a binary safe mode.
    </P
><P
>&#13;     The 'b' character is ignored on all POSIX conforming systems which treat
     binary and text files in the same way.  It is a good idea to specify the 'b'
     character whenever your stream is accessing data where the full 8 bits
     are important, so that your code will work when compiled on a system
     where the 'b' flag is important.
    </P
><P
>&#13;     Any local files created by the streams API will have their initial permissions set
     according to the operating system defaults - under Unix based systems
     this means that the umask of the process will be used.  Under Windows,
     the file will be owned by the creating process.
     Any remote files will be created according to the URL wrapper that was
     used to open the file, and the credentials supplied to the remote server.
    </P
><P
>&#13;     <P
></P
><DIV
CLASS="variablelist"
><DL
><DT
><TT
CLASS="constant"
><B
>r</B
></TT
></DT
><DD
><P
>&#13;         Open text file for reading.  The stream is positioned at the beginning of
         the file.
        </P
></DD
><DT
><TT
CLASS="constant"
><B
>r+</B
></TT
></DT
><DD
><P
>&#13;         Open text file for reading and writing.  The stream is positioned at the beginning of
         the file.
        </P
></DD
><DT
><TT
CLASS="constant"
><B
>w</B
></TT
></DT
><DD
><P
>&#13;         Truncate the file to zero length or create text file for writing.
         The stream is positioned at the beginning of the file.
        </P
></DD
><DT
><TT
CLASS="constant"
><B
>w+</B
></TT
></DT
><DD
><P
>&#13;         Open text file for reading and writing.  The file is created if
         it does not exist, otherwise it is truncated. The stream is positioned at
         the beginning of the file.
        </P
></DD
><DT
><TT
CLASS="constant"
><B
>a</B
></TT
></DT
><DD
><P
>&#13;         Open for writing.  The file is created if it does not exist.
         The stream is positioned at the end of the file.
        </P
></DD
><DT
><TT
CLASS="constant"
><B
>a+</B
></TT
></DT
><DD
><P
>&#13;         Open text file for reading and writing.  The file is created if
         it does not exist. The stream is positioned at the end of the file.
        </P
></DD
></DL
></DIV
>    
    </P
><P
>&#13;     <VAR
CLASS="parameter"
>options</VAR
> affects how the path/URL of the stream is
     interpreted, safe mode checks and actions taken if there is an error during opening
     of the stream.  See <A
HREF="streams.options.html"
>Stream open options</A
> for
     more information about options.
    </P
><P
>&#13;     If <VAR
CLASS="parameter"
>opened</VAR
> is not NULL, it will be set to a string containing
     the name of the actual file/resource that was opened.  This is important when the
     options include <TT
CLASS="constant"
><B
>USE_PATH</B
></TT
>, which causes the include_path to be searched for the
     file.  You, the caller, are responsible for calling <B
CLASS="function"
>efree()</B
> on
     the filename returned in this parameter.
    </P
><DIV
CLASS="note"
><BLOCKQUOTE
CLASS="note"
><P
><B
>Not&#227;: </B
>
      If you specified <TT
CLASS="constant"
><B
>STREAM_MUST_SEEK</B
></TT
> in <VAR
CLASS="parameter"
>options</VAR
>,
      the path returned in <VAR
CLASS="parameter"
>opened</VAR
> may not be the name of the
      actual stream that was returned to you.  It will, however, be the name of the original
      resource from which the seekable stream was manufactured.
     </P
></BLOCKQUOTE
></DIV
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="streams.php-stream-stat.html"
ACCESSKEY="P"
>Înapoi</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
ACCESSKEY="H"
>Acas&#227;</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="streams.php-stream-read.html"
ACCESSKEY="N"
>Înainte</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>php_stream_stat</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="stream.common-api.html"
ACCESSKEY="U"
>Sus</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>php_stream_read</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>