Explorar o código

get the filename from the properties if no disposition information is
available in the bodystructure.

stekkel %!s(int64=22) %!d(string=hai) anos
pai
achega
5b5ff82062
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      src/download.php

+ 3 - 0
src/download.php

@@ -92,7 +92,10 @@ if (is_object($message->header->disposition)) {
     if (!$filename) {
         $filename = decodeHeader($header->getParameter('name'));
     }    
+} else {
+    $filename = decodeHeader($header->getParameter('name'));
 }
+
 if (strlen($filename) < 1) {
     if ($type1 == 'plain' && $type0 == 'text') {
         $suffix = 'txt';