protected function convertCertToPem($cert)
    {
        $output  = '-----BEGIN CERTIFICATE-----'.PHP_EOL;
        $output .= chunk_split($cert, 64, PHP_EOL);
        $output .= '-----END CERTIFICATE-----'.PHP_EOL;
        return $output;
    }
protected function convertCertToPem($cert)
    {
        $output  = '-----BEGIN CERTIFICATE-----'.PHP_EOL;
        $output .= chunk_split($cert, 64, PHP_EOL);
        $output .= '-----END CERTIFICATE-----'.PHP_EOL;
        return $output;
    }
protected function convertCertToPem ( $ cert ) { $ output = '-----BEGIN CERTIFICATE-----' . PHP_EOL ; $ output .= chunk_split ( $ cert , 64 , PHP_EOL ) ; $ output .= '-----END CERTIFICATE-----' . PHP_EOL ; return $ output ; }
Convert a certificate to PEM format.

@param string $cert X509 certificate to convert to PEM format.

@return string
Convert a certificate to PEM format .