Esempio n. 1
0
 /**
  * Return true if there is that path is fully expanded.
  * @return boolean
  */
 public function has_root()
 {
     return has_root($this->_text, $this->options());
 }
Esempio n. 2
0
/**
 * Create a full path out of the given fragment.
 * Prepends the current directory if the fragment is not already
 * a full path.
 * @param string $f
 * @param FILE_OPTIONS $opts
 * @return string
 */
function ensure_has_full_path($f, $opts = null)
{
    if (!has_root($f, $opts)) {
        $Result = join_paths(getcwd(), $f, $opts);
    } else {
        $Result = $f;
    }
    return $Result;
}