px-files/_sys/php/px.php
public function path_files( $localpath_resource = null ){
		if( $this->site() !== false ){
			$tmp_page_info = $this->site()->get_current_page_info();
			$path_content = $tmp_page_info['content'];
			unset($tmp_page_info);
		}
		if( @is_null($path_content) ){
			$path_content = $this->req()->get_request_file_path();
		}

		$rtn = '';
		if( is_callable($this->conf->path_files) ){
			// コールバック関数が設定された場合
			$rtn = call_user_func($this->conf->path_files, $this->fs()->normalize_path($path_content) );
		}elseif( is_string($this->conf->path_files) && strpos(trim($this->conf->path_files), 'function') === 0 ){
			// function で始まる文字列が設定された場合
			$rtn = call_user_func(eval('return '.$this->conf->path_files.';'), $this->fs()->normalize_path($path_content) );
		}else{
			$rtn = $this->conf->path_files;
			$data = array(
				'dirname'=>$this->fs()->normalize_path(dirname($path_content)),
				'filename'=>basename($this->fs()->trim_extension($path_content)),
				'ext'=>strtolower($this->fs()->get_extension($path_content)),
			);
			$rtn = str_replace( '{$dirname}', $data['dirname'], $rtn );
			$rtn = str_replace( '{$filename}', $data['filename'], $rtn );
			$rtn = str_replace( '{$ext}', $data['ext'], $rtn );
		}

		$rtn = preg_replace( '/^\/*/', '/', $rtn );
		$rtn = preg_replace( '/\/*$/', '', $rtn ).'/';
		$rtn = $rtn.$localpath_resource;
		if( $this->fs()->is_dir('./'.$rtn) ){
			$rtn .= '/';
		}
		$rtn = $this->href( $rtn );
		$rtn = $this->fs()->normalize_path($rtn);
		$rtn = preg_replace( '/^\/+/', '/', $rtn );
		return $rtn;
	}
public function path_files( $localpath_resource = null ){
		if( $this->site() !== false ){
			$tmp_page_info = $this->site()->get_current_page_info();
			$path_content = $tmp_page_info['content'];
			unset($tmp_page_info);
		}
		if( @is_null($path_content) ){
			$path_content = $this->req()->get_request_file_path();
		}

		$rtn = '';
		if( is_callable($this->conf->path_files) ){
			// コールバック関数が設定された場合
			$rtn = call_user_func($this->conf->path_files, $this->fs()->normalize_path($path_content) );
		}elseif( is_string($this->conf->path_files) && strpos(trim($this->conf->path_files), 'function') === 0 ){
			// function で始まる文字列が設定された場合
			$rtn = call_user_func(eval('return '.$this->conf->path_files.';'), $this->fs()->normalize_path($path_content) );
		}else{
			$rtn = $this->conf->path_files;
			$data = array(
				'dirname'=>$this->fs()->normalize_path(dirname($path_content)),
				'filename'=>basename($this->fs()->trim_extension($path_content)),
				'ext'=>strtolower($this->fs()->get_extension($path_content)),
			);
			$rtn = str_replace( '{$dirname}', $data['dirname'], $rtn );
			$rtn = str_replace( '{$filename}', $data['filename'], $rtn );
			$rtn = str_replace( '{$ext}', $data['ext'], $rtn );
		}

		$rtn = preg_replace( '/^\/*/', '/', $rtn );
		$rtn = preg_replace( '/\/*$/', '', $rtn ).'/';
		$rtn = $rtn.$localpath_resource;
		if( $this->fs()->is_dir('./'.$rtn) ){
			$rtn .= '/';
		}
		$rtn = $this->href( $rtn );
		$rtn = $this->fs()->normalize_path($rtn);
		$rtn = preg_replace( '/^\/+/', '/', $rtn );
		return $rtn;
	}
ローカルリソースディレクトリのパスを得る。

@param string $localpath_resource ローカルリソースのパス
@return string ローカルリソースの実際の絶対パス