API16

JStreamString/url stat

< API16:JStreamString

The "API16" namespace is an archived namespace. This page contains information for a Joomla! version which is no longer supported. It exists only as a historical reference, it will not be improved and its content may be incomplete and/or contain broken links.

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;
}



Examples

Code Examples


Advertisement