Loading image.php +6 −4 Original line number Diff line number Diff line Loading @@ -365,10 +365,11 @@ class Image { * @param $size int * @param $len int * @param $key string * @param $path string **/ function captcha($font,$size=24,$len=5,$key=NULL) { function captcha($font,$size=24,$len=5,$key=NULL,$path='') { $fw=Base::instance(); foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) if (is_file($path=$dir.$font)) { $seed=strtoupper(substr(uniqid(),-$len)); $block=$size*3; Loading Loading @@ -513,14 +514,15 @@ class Image { * Instantiate image * @param $file string * @param $flag bool * @param $path string **/ function __construct($file=NULL,$flag=FALSE) { function __construct($file=NULL,$flag=FALSE,$path='') { $this->flag=$flag; if ($file) { $fw=Base::instance(); // Create image from file $this->file=$file; foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) if (is_file($dir.$file)) { $this->data=imagecreatefromstring($fw->read($dir.$file)); imagesavealpha($this->data,TRUE); Loading web.php +3 −2 Original line number Diff line number Diff line Loading @@ -490,8 +490,9 @@ class Web extends Prefab { * @param $files string|array * @param $mime string * @param $header bool * @param $path string **/ function minify($files,$mime=NULL,$header=TRUE) { function minify($files,$mime=NULL,$header=TRUE,$path='') { $fw=Base::instance(); if (is_string($files)) $files=$fw->split($files); Loading @@ -500,7 +501,7 @@ class Web extends Prefab { preg_match('/\w+$/',$files[0],$ext); $cache=Cache::instance(); $dst=''; foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) foreach ($files as $file) if (is_file($save=$fw->fixslashes($dir.$file))) { if ($fw->get('CACHE') && Loading Loading
image.php +6 −4 Original line number Diff line number Diff line Loading @@ -365,10 +365,11 @@ class Image { * @param $size int * @param $len int * @param $key string * @param $path string **/ function captcha($font,$size=24,$len=5,$key=NULL) { function captcha($font,$size=24,$len=5,$key=NULL,$path='') { $fw=Base::instance(); foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) if (is_file($path=$dir.$font)) { $seed=strtoupper(substr(uniqid(),-$len)); $block=$size*3; Loading Loading @@ -513,14 +514,15 @@ class Image { * Instantiate image * @param $file string * @param $flag bool * @param $path string **/ function __construct($file=NULL,$flag=FALSE) { function __construct($file=NULL,$flag=FALSE,$path='') { $this->flag=$flag; if ($file) { $fw=Base::instance(); // Create image from file $this->file=$file; foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) if (is_file($dir.$file)) { $this->data=imagecreatefromstring($fw->read($dir.$file)); imagesavealpha($this->data,TRUE); Loading
web.php +3 −2 Original line number Diff line number Diff line Loading @@ -490,8 +490,9 @@ class Web extends Prefab { * @param $files string|array * @param $mime string * @param $header bool * @param $path string **/ function minify($files,$mime=NULL,$header=TRUE) { function minify($files,$mime=NULL,$header=TRUE,$path='') { $fw=Base::instance(); if (is_string($files)) $files=$fw->split($files); Loading @@ -500,7 +501,7 @@ class Web extends Prefab { preg_match('/\w+$/',$files[0],$ext); $cache=Cache::instance(); $dst=''; foreach ($fw->split($fw->get('UI')) as $dir) foreach ($fw->split($path?:$fw->get('UI')) as $dir) foreach ($files as $file) if (is_file($save=$fw->fixslashes($dir.$file))) { if ($fw->get('CACHE') && Loading