Ejemplo n.º 1
0
 /** Return FileModel path and filename
  * @param bool $base
  * @return string
  */
 public function getFilePath($base = true)
 {
     $separator = $base ? DIRECTORY_SEPARATOR : '/';
     $path = App::getAppc()['directories']['media'] . $separator . $this->getShortClassName() . $separator . floor((int) $this->fileid / 200) . $separator . $this->fileid . (isset($this->extension) ? '.' . $this->extension : '');
     return $base ? App::basePath() . $path : $separator . $path;
 }
Ejemplo n.º 2
0
 public function getImageFile()
 {
     return App::basePath() . $this->getImageUrl();
 }