@@ 345-363 (lines=19) @@ | ||
342 | $p_result_list = []; |
|
343 | ||
344 | // ----- Look if the $p_filelist is really an array |
|
345 | if (is_array($p_filelist)) { |
|
346 | // ----- Look if the first element is also an array |
|
347 | // This will mean that this is a file description entry |
|
348 | if (isset($p_filelist[0]) && is_array($p_filelist[0])) { |
|
349 | $v_att_list = $p_filelist; |
|
350 | } else { |
|
351 | // ----- The list is a list of string names |
|
352 | $v_string_list = $p_filelist; |
|
353 | } |
|
354 | } elseif (is_string($p_filelist)) { |
|
355 | // ----- Look if the $p_filelist is a string |
|
356 | // ----- Create a list from the string |
|
357 | $v_string_list = explode(PCLZIP_SEPARATOR, $p_filelist); |
|
358 | } else { |
|
359 | // ----- Invalid variable type for $p_filelist |
|
360 | self::privErrorLog(PCLZIP_ERR_INVALID_PARAMETER, 'Invalid variable type p_filelist'); |
|
361 | ||
362 | return 0; |
|
363 | } |
|
364 | ||
365 | // ----- Reformat the string list |
|
366 | if (sizeof($v_string_list) != 0) { |
|
@@ 517-535 (lines=19) @@ | ||
514 | $p_result_list = []; |
|
515 | ||
516 | // ----- Look if the $p_filelist is really an array |
|
517 | if (is_array($p_filelist)) { |
|
518 | // ----- Look if the first element is also an array |
|
519 | // This will mean that this is a file description entry |
|
520 | if (isset($p_filelist[0]) && is_array($p_filelist[0])) { |
|
521 | $v_att_list = $p_filelist; |
|
522 | } else { |
|
523 | // ----- The list is a list of string names |
|
524 | $v_string_list = $p_filelist; |
|
525 | } |
|
526 | } elseif (is_string($p_filelist)) { |
|
527 | // ----- Look if the $p_filelist is a string |
|
528 | // ----- Create a list from the string |
|
529 | $v_string_list = explode(PCLZIP_SEPARATOR, $p_filelist); |
|
530 | } else { |
|
531 | // ----- Invalid variable type for $p_filelist |
|
532 | self::privErrorLog(PCLZIP_ERR_INVALID_PARAMETER, "Invalid variable type '" . gettype($p_filelist) . "' for p_filelist"); |
|
533 | ||
534 | return 0; |
|
535 | } |
|
536 | ||
537 | // ----- Reformat the string list |
|
538 | if (sizeof($v_string_list) != 0) { |