Actions

API16

JStreamString/url stat

From Joomla! Documentation

< API16:JStreamString
Replacement filing cabinet.png
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.

[Edit Descripton]

Description:JStreamString/url stat

Contents

Syntax

url_stat($path, $flags=0)
Parameter Name Default Value Description
$path
$flags 0

Defined in

libraries/joomla/filesystem/streams/string.php

Importing

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

Source Body

function url_stat($path, $flags=0)
{
        $now = time();
        $string =& JStringController::getRef(str_replace('string://','',$path));
        $stat = Array(
                'dev'=> 0,
                'ino'=> 0,
                'mode'=>0,
                'nlink'=>1,
                'uid'=>0,
                'gid'=>0,
                'rdev'=>0,
                'size'=>strlen($string),
                'atime'=>$now,
                'mtime'=>$now,
                'ctime'=>$now,
                'blksize'=>'512',
                'blocks'=>ceil(strlen($string) / 512)
        );
        return $stat;
}

[Edit See Also] SeeAlso:JStreamString/url stat

Examples

<CodeExamplesForm />