void addFile(
string
$filename, [string
$localname = ''], [string
$mimetype = 'text/text']
)
|
|
Adds a file to a ZIP archive from the given path.
Parameters:
|
string |
$localname: |
The name of the entry to create. |
|
string |
$filename: |
The path to the file to add. |
|
string |
$mimetype: |
Mime type of the file. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::addFile ( )
void addFromString(
string
$localname, string
$contents, [string
$mimetype = 'text/text']
)
|
|
Add a file to a ZIP archive using its contents.
Parameters:
|
string |
$localname: |
The name of the entry to create. |
|
string |
$contents: |
The contents to use to create the entry. It is used in a binary safe mode. |
|
string |
$mimetype: |
Mime type of the file. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::addFromString ( )
void close(
[boolean
$write = true]
)
|
|
Close opened or created archive and save changes. This method is automatically called at the end of the script.
Parameters:
|
boolean |
$write: |
Should we write to archive? - Default is true. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::close ( )
Redefined in descendants as:
void deleteIndex(
int
$index
)
|
|
Delete an entry in the archive using its index.
Parameters:
|
int |
$index: |
Index of the entry to delete. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::deleteIndex ( )
void deleteName(
string
$name
)
|
|
Delete an entry in the archive using its name.
Parameters:
|
string |
$name: |
Name of the entry to delete. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::deleteName ( )
DOMDocument getDOMFromName(
string
$filename
)
|
|
Retrieve file from archive as a DOM document.
Parameters:
API Tags:
| Return: | The file as a DOM document. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Retrieve file list.
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Retreive the manifest document as a ManifestDocument object.
API Tags:
| Return: | The manifest document. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Retrieve mime type of the OpenDocument archive.
API Tags:
| Return: | Current mime type of the OpenDocument archive. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
OpenDocumentArchive __construct(
[string
$mimetype = '']
)
|
|
Constructor method.
Parameters:
|
string |
$mimetype: |
Mime type of the achrive |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefined in descendants as:
mixed open(
string
$filename, [int
$flags = 0], [
$mimetype = '']
)
|
|
Opens a new zip archive for reading, writing or modifying.
If we create a new archive, we add to files. First the manifest document stored in the ManifestDocument and second the file 'mimetype' which only include the
Parameters:
|
string |
$filename: |
The file name of the ZIP archive to open. |
|
int |
$flags: |
The mode to use to open the archive. |
|
|
$mimetype: |
|
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::open ( )
Redefined in descendants as:
-
OpenDocumentAbstract::open()
: Open an OpenDocument and read the meta, settings, content and styles data out of the ususal xml files and stores them into their attributes.
void renameIndex(
int
$index, string
$newname
)
|
|
Renames an entry defined by its index.
Parameters:
|
int |
$index: |
Index of the entry to rename. |
|
string |
$newname: |
New name. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::renameIndex ( )
void renameName(
string
$name, string
$newname
)
|
|
Renames an entry defined by its name.
Parameters:
|
string |
$name: |
Name of the entry to rename. |
|
string |
$newname: |
New name. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::renameName ( )
void setMimeType(
string
$mimetype
)
|
|
Set mime type of the OpenDocument archive.
Therefor we delete the file 'mimetype' in the current OpenDocument archive and add a new file 'mimetype' with the new mime type given as parameter $mimetype.
Parameters:
|
string |
$mimetype: |
New mime type of the OpenDocument archive. |
API Tags:
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
array|bool statName(
string
$name, [int
$flags = 0]
)
|
|
Get the details of an entry defined by its name.
The function obtains information about the entry defined by its name.
Parameters:
|
string |
$name: |
Name of the entry. |
|
int |
$flags: |
The flags argument specifies how the name lookup should be done. Also, ZIPARCHIVE::FL_UNCHANGED may be ORed to it to request information about the original file in the archive, ignoring any changes made. |
API Tags:
| Return: | Returns an array containing the entry details or FALSE on failure. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::statName ( )
Undo all changes done in the archive. Always returns false!
API Tags:
| Return: | Returns true if success, false if not. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::unchangeAll ( )
boolean unchangeIndex(
int
$index
)
|
|
Revert all changes done to an entry at the given index.
Always returns false!
Parameters:
|
int |
$index: |
Index of the entry. |
API Tags:
| Return: | Returns true if success, false if not. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::unchangeIndex ( )
boolean unchangeName(
string
$index
)
|
|
Revert all changes done to an entry with the given name.
Always returns false!
Parameters:
|
string |
$index: |
Name of the entry. |
API Tags:
| Return: | Returns true if success, false if not. |
| Access: | public |
Information Tags:
| Since: | 0.5.0 - 08. Feb. 2007 |
Redefinition of:
- ZipArchive::unchangeName ( )