Go to the source code of this file.
Namespaces | |
FDL | |
Functions | |
rezizelocalimage ($img, $size, $basedest) | |
getVaultPauth ($vid) | |
verifyAccessByVaultId ($vid) | |
getVaultCacheImage ($vid, $size) | |
Variables | |
const | MAX_RESIZE_IMG_SIZE 512 |
$size = isset($_GET["size"]) ? $_GET["size"] : null | |
if(!$size) if(!$size) if(!preg_match('/^H? | else [0-9]+(px)?$/', $size)) |
if(!$img) | $location = '' |
$dir = dirname($_SERVER["SCRIPT_NAME"]) | |
$ldir = DEFAULT_PUBDIR | |
$path = $turl["path"] | |
if($path[0]== '/') | $realfile = realpath($path) |
if(!$realfile) | $itselfName = $_SERVER["SCRIPT_FILENAME"] |
$itselfdir = realpath(dirname($itselfName)) | |
if(substr(dirname($realfile), 0, strlen($itselfdir))!=$itselfdir) if(strtok(substr($realfile, strlen($itselfdir)), '/')=="var") | $cmd = sprintf('file -ib %s', escapeshellarg($realfile)) |
$tsize = getimagesize($realfile) | |
$basedest = sprintf("/var/cache/image/%s-%s.png", $size, basename(str_replace("/", "_", $localimage))) | |
$dest = DEFAULT_PUBDIR . $basedest | |
getVaultCacheImage | ( | $vid, | |
$size | |||
) |
Definition at line 104 of file resizeimg.php.
getVaultPauth | ( | $vid | ) |
rezizelocalimage | ( | $img, | |
$size, | |||
$basedest | |||
) |
Definition at line 21 of file resizeimg.php.
verifyAccessByVaultId | ( | $vid | ) |
Return true if access granted
int | $vid | vault identifier |
Definition at line 79 of file resizeimg.php.
$basedest = sprintf("/var/cache/image/%s-%s.png", $size, basename(str_replace("/", "_", $localimage))) |
Definition at line 230 of file resizeimg.php.
if (substr(dirname($realfile), 0, strlen($itselfdir))!=$itselfdir) if (strtok(substr($realfile, strlen($itselfdir)), '/')=="var") $cmd = sprintf('file -ib %s', escapeshellarg($realfile)) |
Definition at line 211 of file resizeimg.php.
$dest = DEFAULT_PUBDIR . $basedest |
Definition at line 231 of file resizeimg.php.
$dir = dirname($_SERVER["SCRIPT_NAME"]) |
Definition at line 144 of file resizeimg.php.
$itselfdir = realpath(dirname($itselfName)) |
Definition at line 197 of file resizeimg.php.
Definition at line 196 of file resizeimg.php.
$ldir = DEFAULT_PUBDIR |
Definition at line 145 of file resizeimg.php.
else $location = '' |
Definition at line 143 of file resizeimg.php.
$path = $turl["path"] |
Definition at line 172 of file resizeimg.php.
Definition at line 176 of file resizeimg.php.
$size = isset($_GET["size"]) ? $_GET["size"] : null |
Definition at line 110 of file resizeimg.php.
$tsize = getimagesize($realfile) |
Definition at line 213 of file resizeimg.php.
if (file_exists($dest)&&filemtime($dest) >=filemtime(DEFAULT_PUBDIR."/$localimage")) else |
Definition at line 127 of file resizeimg.php.
const MAX_RESIZE_IMG_SIZE 512 |
Definition at line 20 of file resizeimg.php.