filename); } function EditableFile($filename) { import('lib.pkp.classes.file.FileWrapper'); $this->filename = $filename; $wrapper =& FileWrapper::wrapper($this->filename); $this->setContents($wrapper->contents()); } function &getContents() { return $this->contents; } function setContents(&$contents) { $this->contents =& $contents; } function write() { $fp = fopen($this->filename, 'w+'); if ($fp === false) return false; fwrite($fp, $this->getContents()); fclose($fp); return true; } function xmlEscape($value) { $escapedValue = XMLNode::xmlentities($value, ENT_NOQUOTES); if ($value !== $escapedValue) return ""; return $value; } } ?>