downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

openssl_free_key> <openssl_encrypt
[edit] Last updated: Fri, 07 Jun 2013

view this page in

openssl_error_string

(PHP 4 >= 4.0.6, PHP 5)

openssl_error_stringOpenSSL hata iletisini döndürür

Açıklama

string openssl_error_string ( void )

OpenSSL kütüphanesinde son oluşan hatanın iletisini döndürür. Hata iletileri bir yığıta kaydedilir, dolayısıyla tüm hata iletilerini toplamak için bu işlevin defalarca çağrılması gerekir.

Dönen Değerler

Döndürülecek hata iletisi kalmamışsa FALSE, varsa bir hata dizgesi döndürür.

Örnekler

Örnek 1 - openssl_error_string() örneği

<?php
// Bazı openssl işlevlerinin başarısız olduğunu varsayalım
while ($msg openssl_error_string())
    echo 
$msg "<br />\n";
?>



add a note add a note User Contributed Notes openssl_error_string - [1 notes]
up
0
greg at gregmaclellan dot com
8 years ago
Becareful when using this function to check errors, as it seems to read from a buffer of errors, which could include errors from another script or process that was using openssl functions. (I was surprised to find it returing error messages before I had called any openssl_* functions)

To clear the errors, you can do:

while ($err = openssl_error_string());

before using openssl functions. I'm not totally sure of the effect this will have on other threads though, maybe someone can clairify.

 
show source | credits | stats | sitemap | contact | advertising | mirror sites