title: Fatal error: Call to undefined function mcrypt_encrypt()
body: <p><strong>NOTE:</strong> The libraries MCrypt support depend on have not been updated in years and MCrypt should no longer be considered a viable or secure method of encrypting data.  What's more, MCrypt has been deprecated in PHP 5, and removed entirely in PHP 7.  If you have any code that runs MCrypt you should refactor it to use a more modern encryption library.  </p>
  
  <hr>
  
  <p>Does anyone know why this error message: <code>(Call to undefined function mcrypt_encrypt() )</code> displays when I run the following code below?</p>
  
  <p>Am I missing some steps perhaps any setting in PHP I have to do before this code can work?</p>
  
  <pre class="lang-php prettyprint-override"><code>$key = 'password to (en/de)crypt';
  $string = 'string to be encrypted';
  
  $test = mcrypt_encrypt(MCRYPT_RIJNDAEL_256, md5($key),
              $string, MCRYPT_MODE_CBC, md5(md5($key)));
  </code></pre>