title: Show a message if user does NOT exist in the DB
body: <p>I have 4 conditions.</p>
  
  <ol>
  <li>If nothing is filled, go to a page. &lt;--- Working fine</li>
  <li>If username or password is wrong, go to a page. &lt;--- Working fine</li>
  <li>If username is not activated, go to a page. &lt;--- Working fine</li>
  <li>If username does not exist in the DB, go to a page. &lt;--- Not Working :(</li>
  </ol>
  
  <p>But I'm having trouble with my fourth condition: It does not go to the desired page, <code>/account/no/</code>.</p>
  
  <p>What am I doing wrong? This is the relevant piece of code for the fourth condition:</p>
  
  <pre><code>//////////////////////////////////////////////////////////
  # 4th condition IF USER NOT EXIST, then go to /ACCOUNT/NO
  
  $query = "SELECT * FROM users WHERE username='$username'";
    $result = mysqli_query($mysqli,$query)or die(mysqli_error());
    $num_row = mysqli_num_rows($result);
    $row=mysqli_fetch_array($result);
    if( $num_row ==1 )
  
    {
  
  
  if ($_POST['username']!=$row['username']) 
  {
    header('Location: /account/no/');
    exit;
      }
    }
  </code></pre>
  
  <p>HTML Login Form:</p>
  
  <pre><code>&lt;form action="/login/" action="post"&gt;
  &lt;input name="username" type="text"&gt;
  &lt;input name ="password" type="password"&gt;
  &lt;input name="submit" type="submit"&gt;
  &lt;/form&gt;
  </code></pre>