protected function decodeContentTransfer($encodedString, $encodingType)
    {
        if (is_array($encodingType)) {
            $encodingType = $encodingType[0];
        }

        $encodingType = strtolower($encodingType);
        if ($encodingType == 'base64') {
            return base64_decode($encodedString);
        } elseif ($encodingType == 'quoted-printable') {
            return quoted_printable_decode($encodedString);
        } else {
            return $encodedString;
        }
    }
protected function decodeContentTransfer($encodedString, $encodingType)
    {
        if (is_array($encodingType)) {
            $encodingType = $encodingType[0];
        }

        $encodingType = strtolower($encodingType);
        if ($encodingType == 'base64') {
            return base64_decode($encodedString);
        } elseif ($encodingType == 'quoted-printable') {
            return quoted_printable_decode($encodedString);
        } else {
            return $encodedString;
        }
    }
protected function decodeContentTransfer ( $ encodedString , $ encodingType ) { if ( is_array ( $ encodingType ) ) { $ encodingType = $ encodingType [ 0 ] ; } $ encodingType = strtolower ( $ encodingType ) ; if ( $ encodingType == 'base64' ) { return base64_decode ( $ encodedString ) ; } elseif ( $ encodingType == 'quoted-printable' ) { return quoted_printable_decode ( $ encodedString ) ; } else { return $ encodedString ; } }
Decode the string from Content-Transfer-Encoding

@param string $encodedString The string in its original encoded state
@param string $encodingType  The encoding type from the Content-Transfer-Encoding header of the part.

@return string The decoded string
Decode the string from Content - Transfer - Encoding