API16

JStreamString/stream open: Difference between revisions

From Joomla! Documentation

Doxiki (talk | contribs)
No edit summary
m preparing for archive only
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
<span class="editsection" style="font-size:76%;">
<nowiki>[</nowiki>[[Description:JStreamString/stream_open|Edit Descripton]]<nowiki>]</nowiki>
</span>
{{Description:JStreamString/stream_open}}
===Syntax===
===Syntax===
<source lang="php">stream_open($path, $mode, $options, &$opened_path)</source>
<source lang="php">stream_open($path, $mode, $options, &$opened_path)</source>
Line 55: Line 48:
</source>
</source>


<span class="editsection" style="font-size:76%;">
 
<nowiki>[</nowiki>[[SeeAlso:JStreamString/stream_open|Edit See Also]]<nowiki>]</nowiki>
 
</span>
{{SeeAlso:JStreamString/stream_open}}


===Examples===
===Examples===
<CodeExamplesForm />
=== Code Examples ===
<dpl>
<dpl>
  noresultsheader=\n
  noresultsheader=\n
  category=stream_open
  category=stream_open
  category=JStreamString
  category=JStreamString
  category=CodeExample
  namespace=CodeExample
  category=MethodExample
  category=MethodExample
  include=*
  include=*
  format= ,,,
  format= ,,,
</dpl>
</dpl>

Latest revision as of 02:08, 25 March 2017

Syntax

stream_open($path, $mode, $options, &$opened_path)
Parameter Name Default Value Description
$path
$mode
$options
&$opened_path

Defined in

libraries/joomla/filesystem/streams/string.php

Importing

jimport( 'joomla.filesystem.streams.string' );

Source Body

function stream_open($path, $mode, $options, &$opened_path)
{
        $this->_currentstring =& JStringController::getRef(str_replace('string://','',$path));
        if($this->_currentstring)
        {
                $this->_len = strlen($this->_currentstring);
                $this->_pos = 0;
                $this->_stat = $this->url_stat($path, 0);
                return true;
        }
        else {
                return false;
        }
}



Examples

Code Examples