title: Php Email activation
body: <p>Hi In this script when users register on site they shoould receive confrimation email / code but the problem is users never receive it, I can activate it manually on mysql, there is stored activation key:</p>
  
  <p>Here is script, what could be a problem?</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>/**
   * Sends activation email
   */
  function notify_activation($user) {
  
    $app = \Slim\Slim::getInstance();
    
    $message = "Hello, &lt;br&gt;";
    
    $message .= '&lt;br&gt; To activate your &lt;a href="'.app_url().'"&gt;' . get_config('appname') . '&lt;/a&gt; account, please click the following link:&lt;br&gt;';
    
    $activation_link = app_url() . "/activate/" . $user-&gt;activation_token;
    
    $message .= '&lt;a href="'.$activation_link.'"&gt;'.$activation_link.'&lt;/a&gt;';
  
    $subject = get_config('appname') . " : Account Activation";
    
    mail($user-&gt;email, $subject, $message, get_notifier_headers(get_config('admin_email')));
  
  }</code></pre>
  </div>
  </div>
  </p>
  
  <p>Here is the full code: <a href="https://dl.dropboxusercontent.com/s/rwobyfjwvwny91m/phpfile.txt.txt" rel="nofollow">https://dl.dropboxusercontent.com/s/rwobyfjwvwny91m/phpfile.txt.txt</a></p>