Hi,
I wrote a function, which crypts a string, like this:
function enCrypt($txt){
global $key, $iv;
$txt = mcrypt_encrypt (MCRYPT_RIJNDAEL_256, $key, $txt, MCRYPT_MODE_ECB, $iv);
return $txt;
}
I want to turnover the parameter as reference, like this:
function enCrypt(&$txt){
global $key, $iv;
$txt = mcrypt_encrypt (MCRYPT_RIJNDAEL_256, $key, $txt, MCRYPT_MODE_ECB, $iv);
}
But this don't work, any ideas why?
Thanks,
Tanja