PclZip::privConvertHeader2FileInfo()publicWP 1.0

Description : This function takes the file information from the central directory entries and extract the interesting parameters that will be given back. The resulting file infos are set in the array $p_info

$p_info['filename'] : Filename with full path. Given by user (add),
					  extracted in the filesystem (extract).
$p_info['stored_filename'] : Stored filename in the archive.
$p_info['size'] = Size of the file.
$p_info['compressed_size'] = Compressed size of the file.
$p_info['mtime'] = Last modification date of the file.
$p_info['comment'] = Comment associated with the file.
$p_info['folder'] = true/false : indicates if the entry is a folder or not.
$p_info['status'] = status of the action on the file.
$p_info['crc'] = CRC of the file content.

Parameters : Return Values :

{} Это метод класса: PclZip{}

Хуков нет.


null. Ничего.


$PclZip = new PclZip();
$PclZip->privConvertHeader2FileInfo( $p_header, $p_info );
$p_header (обязательный)
$p_info (обязательный) (передается по ссылке — &)

Код PclZip::privConvertHeader2FileInfo() WP 6.0.2

function privConvertHeader2FileInfo($p_header, &$p_info)

  // ----- Get the interesting attributes
  $v_temp_path = PclZipUtilPathReduction($p_header['filename']);
  $p_info['filename'] = $v_temp_path;
  $v_temp_path = PclZipUtilPathReduction($p_header['stored_filename']);
  $p_info['stored_filename'] = $v_temp_path;
  $p_info['size'] = $p_header['size'];
  $p_info['compressed_size'] = $p_header['compressed_size'];
  $p_info['mtime'] = $p_header['mtime'];
  $p_info['comment'] = $p_header['comment'];
  $p_info['folder'] = (($p_header['external']&0x00000010)==0x00000010);
  $p_info['index'] = $p_header['index'];
  $p_info['status'] = $p_header['status'];
  $p_info['crc'] = $p_header['crc'];

  // ----- Return
  return $v_result;