Undefined function sha256()
The Suhosin extension adds the function sha256()
, and even sha256_file()
, to the PHP Core.
With the extension installed:
<?php
var_dump(function_exists('sha256'));
?>
bool(true)
There is no such function in php standard library. Use hash
function instead.
http://php.net/manual/en/function.hash.php
like :
$pass = hash('sha256', $_POST['password']);
You can use
hash( 'sha256', $string );
See http://de.php.net/manual/de/function.hash.php