Page 1 of 1

encrypting problems

Posted: Tue Feb 15, 2005 12:12 pm
by fabby
i sow on a web page a code who encrypt a text, but i can't use mhash function, and i recieved an error like this:
Fatal error: Call to undefined function: mhash() in E:\server\Apache2\htdocs\data\php.php on line 4

Code: Select all

<?php 
    echo("<h3> Implementing mhash </h3>"); 
    $plain_text = "Damn why won't PHP come naturally to me!"; 
    $encrypted_text = mhash(MHASH_CRC32, $plain_text); 
    echo("<p><b> Encrypted text is : </b>"); 
    echo($encrypted_text); 
    ?>
Why and what to do. When i tryed something from php manula, i recieved a same error. Do you know why?


feyd | please use the formatting tags we provide

Posted: Tue Feb 15, 2005 12:19 pm
by feyd
sounds like it's not installed :: http://php.net/mhash :: read the requirements and following sections.