ciao a tutti, io dovrei fare la seguenti trasformazione di stringa:

ISO -> UTF-8 -> SHA1 -> BASE64

codice:
<?php

$str = '123456

';
$u8 = iconv("ISO-8859-1","UTF-8",$str);
$hash1 = sha1($u8);
$b64 = base64_encode($hash1);
echo "ISO:. ".$str;
echo "UTF-8:. ".$u8."

";
echo "SHA1:. ".$hash1;
echo "

BASE64:. ".$b64;
echo "

Key reale:. fEqNCco3Yq9h5ZUglD3CZJT4lBs="; //questa è la key ke dovrebbe spuntare

?>
questo è quello che ho fatto, me li converte tutti meno che UTF-8.