Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function compileFile($fname, $outFname = null) { if (!is_readable($fname)) { throw new Exception('load error: failed to find '.$fname); } $pi = pathinfo($fname); $oldImport = $this->importDir; $this->importDir = (array)$this->importDir; $this->importDir[] = $pi['dirname'].'/'; $this->addParsedFile($fname); $out = $this->compile(file_get_contents($fname), $fname); $this->importDir
- = $oldImport; if ($outFname !== null) { return file_put_contents($outFname, $out); } return $out; }
- protected function configurePath() {
- $target_file = $this->computeTargetPath();
- $this->source_path = WP_CONTENT_DIR.preg_replace('#^'.content_url().'#U', '', $this->stylesheet->src);
- $this->source_uri = $this->stylesheet->src;
- $this->target_path = self::$upload_dir.$target_file;
- $this->target_uri = self::$upload_uri.$target_file;
- $this->setSourceTimestamp(filemtime($this->source_path)); }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement