XCL Web Application Platform 2.5.0
The XoopsCube Legacy Project
Loading...
Searching...
No Matches
zipfile Class Reference

Public Member Functions

 unix2DosTime ($unixtime=0)
 
 addFile ($data, $name, $time=0)
 
 file ()
 

Data Fields

 $datasec = []
 
 $ctrl_dir = []
 
 $eof_ctrl_dir = "\x50\x4b\x05\x06\x00\x00\x00\x00"
 
 $old_offset = 0
 

Detailed Description

Definition at line 16 of file class.zipfile.php.

Member Function Documentation

◆ addFile()

addFile ( $data,
$name,
$time = 0 )

Adds "file" to archive

Parameters
stringfile contents
stringname of the file in the archive (may contains the path)
intthe current timestamp

@access public

Definition at line 84 of file class.zipfile.php.

◆ file()

file ( )

Dumps out file

Returns
string the zipped file

@access public

Definition at line 162 of file class.zipfile.php.

◆ unix2DosTime()

unix2DosTime ( $unixtime = 0)

Converts an Unix timestamp to a four byte DOS date and time format (date in high two bytes, time in low two bytes allowing magnitude comparison).

Parameters
intthe current Unix timestamp
Returns
int the current date in a four byte DOS format

@access private

Definition at line 57 of file class.zipfile.php.

Field Documentation

◆ $ctrl_dir

$ctrl_dir = []

Central directory

Definition at line 30 of file class.zipfile.php.

◆ $datasec

$datasec = []

Array to store compressed data

Definition at line 23 of file class.zipfile.php.

◆ $eof_ctrl_dir

$eof_ctrl_dir = "\x50\x4b\x05\x06\x00\x00\x00\x00"

End of central directory record

Definition at line 37 of file class.zipfile.php.

◆ $old_offset

$old_offset = 0

Last offset position

Definition at line 44 of file class.zipfile.php.


The documentation for this class was generated from the following file: