function _openWrite() {
if ($this->_compress_type == 'gz') {
$this->_file = @gzopen($this->_tarname, "wb9");
}
else {
if ($this->_compress_type == 'bz2') {
$this->_file = @bzopen($this->_tarname, "w");
}
else {
if ($this->_compress_type == 'none') {
$this->_file = @fopen($this->_tarname, "wb");
}
else {
$this
->_error('Unknown or missing compression type (' . $this->_compress_type . ')');
}
}
}
if ($this->_file == 0) {
$this
->_error('Unable to open in write mode \'' . $this->_tarname . '\'');
return false;
}
return true;
}